michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: /*** Status and progress indicator ***/ michael@0: michael@0: #downloads-animation-container { michael@0: min-height: 1px; michael@0: min-width: 1px; michael@0: height: 1px; michael@0: margin-bottom: -1px; michael@0: /* Makes the outermost animation container element positioned, so that its michael@0: contents are rendered over the main browser window in the Z order. michael@0: This is required by the animated event notification. */ michael@0: position: relative; michael@0: /* The selected tab may overlap #downloads-indicator-notification */ michael@0: z-index: 5; michael@0: } michael@0: michael@0: /*** Main indicator icon ***/ michael@0: michael@0: #downloads-button[cui-areatype="toolbar"] > #downloads-indicator-anchor > #downloads-indicator-icon { michael@0: background: -moz-image-rect(url("chrome://browser/skin/Toolbar.png"), michael@0: 0, 198, 18, 180) center no-repeat; michael@0: min-width: 18px; michael@0: min-height: 18px; michael@0: } michael@0: michael@0: toolbar[brighttext] #downloads-button[cui-areatype="toolbar"]:not([attention]) > #downloads-indicator-anchor > #downloads-indicator-icon { michael@0: background: -moz-image-rect(url("chrome://browser/skin/Toolbar-inverted.png"), michael@0: 0, 198, 18, 180) center no-repeat; michael@0: } michael@0: michael@0: #downloads-button[cui-areatype="toolbar"][attention] > #downloads-indicator-anchor > #downloads-indicator-icon { michael@0: background-image: url("chrome://browser/skin/downloads/download-glow.png"); michael@0: } michael@0: michael@0: #downloads-button[cui-areatype="menu-panel"][attention] { michael@0: list-style-image: url("chrome://browser/skin/downloads/download-glow-menuPanel.png"); michael@0: -moz-image-region: auto; michael@0: } michael@0: michael@0: /* In the next few rules, we use :not([counter]) as a shortcut that is michael@0: equivalent to -moz-any([progress], [paused]). */ michael@0: michael@0: #downloads-button:not([counter]) > #downloads-indicator-anchor > #downloads-indicator-progress-area > #downloads-indicator-counter { michael@0: background: -moz-image-rect(url("chrome://browser/skin/Toolbar-small.png"), michael@0: 0, 16, 16, 0) center no-repeat; michael@0: background-size: 12px; michael@0: } michael@0: michael@0: toolbar[brighttext] #downloads-button:not([counter]):not([attention]) > #downloads-indicator-anchor > #downloads-button-progress-area > #downloads-indicator-counter { michael@0: background-image: -moz-image-rect(url("chrome://browser/skin/Toolbar-inverted.png"), 0, 198, 18, 180); michael@0: } michael@0: michael@0: #downloads-button:not([counter])[attention] > #downloads-indicator-anchor > #downloads-indicator-progress-area > #downloads-indicator-counter { michael@0: background-image: url("chrome://browser/skin/downloads/download-glow.png"); michael@0: } michael@0: michael@0: /*** Download notifications ***/ michael@0: michael@0: #downloads-indicator-notification { michael@0: opacity: 0; michael@0: background-size: 16px; michael@0: background-position: center; michael@0: background-repeat: no-repeat; michael@0: width: 16px; michael@0: height: 16px; michael@0: } michael@0: michael@0: @keyframes downloadsIndicatorNotificationStartRight { michael@0: from { opacity: 0; transform: translate(-128px, 128px) scale(8); } michael@0: 20% { opacity: .85; animation-timing-function: ease-out; } michael@0: to { opacity: 0; transform: translate(0) scale(1); } michael@0: } michael@0: michael@0: @keyframes downloadsIndicatorNotificationStartLeft { michael@0: from { opacity: 0; transform: translate(128px, 128px) scale(8); } michael@0: 20% { opacity: .85; animation-timing-function: ease-out; } michael@0: to { opacity: 0; transform: translate(0) scale(1); } michael@0: } michael@0: michael@0: #downloads-notification-anchor[notification="start"] > #downloads-indicator-notification { michael@0: background-image: url("chrome://browser/skin/downloads/download-notification-start.png"); michael@0: animation-name: downloadsIndicatorNotificationStartRight; michael@0: animation-duration: 1s; michael@0: } michael@0: michael@0: #downloads-notification-anchor[notification="start"]:-moz-locale-dir(rtl) > #downloads-indicator-notification { michael@0: animation-name: downloadsIndicatorNotificationStartLeft; michael@0: } michael@0: michael@0: @keyframes downloadsIndicatorNotificationFinish { michael@0: from { opacity: 0; transform: scale(1); } michael@0: 20% { opacity: .65; animation-timing-function: ease-in; } michael@0: to { opacity: 0; transform: scale(8); } michael@0: } michael@0: michael@0: #downloads-notification-anchor[notification="finish"] > #downloads-indicator-notification { michael@0: background-image: url("chrome://browser/skin/downloads/download-notification-finish.png"); michael@0: animation-name: downloadsIndicatorNotificationFinish; michael@0: animation-duration: 1s; michael@0: } michael@0: michael@0: /*** Progress bar and text ***/ michael@0: michael@0: #downloads-indicator-counter { michael@0: height: 10px; michael@0: margin: 0; michael@0: color: hsl(0,0%,30%); michael@0: text-shadow: 0 1px 0 hsla(0,0%,100%,.5); michael@0: font-size: 10px; michael@0: line-height: 10px; michael@0: text-align: center; michael@0: } michael@0: michael@0: toolbar[brighttext] #downloads-indicator-counter { michael@0: color: white; michael@0: text-shadow: 0 0 1px rgba(0,0,0,.7), michael@0: 0 1px 1.5px rgba(0,0,0,.5); michael@0: } michael@0: michael@0: #downloads-indicator-progress { michael@0: width: 18px; michael@0: height: 6px; michael@0: min-width: 0; michael@0: min-height: 0; michael@0: margin-top: 1px; michael@0: margin-bottom: 2px; michael@0: border-radius: 2px; michael@0: box-shadow: 0 1px 0 hsla(0,0%,100%,.4); michael@0: } michael@0: michael@0: #downloads-indicator-progress > .progress-bar { michael@0: -moz-appearance: none; michael@0: min-width: 0; michael@0: min-height: 0; michael@0: /* The background-clip: border-box; and background-image: none; are there to expand the background-color behind the border */ michael@0: background-clip: padding-box, border-box; michael@0: background-color: rgb(255, 135, 94); michael@0: background-image: linear-gradient(transparent 1px, rgba(255, 255, 255, 0.4) 1px, rgba(255, 255, 255, 0.4) 2px, transparent 2px), none; michael@0: border: 1px solid; michael@0: border-color: rgba(0,43,86,.6) rgba(0,43,86,.4) rgba(0,43,86,.4); michael@0: border-radius: 2px 0 0 2px; michael@0: } michael@0: michael@0: #downloads-indicator-progress > .progress-remainder { michael@0: -moz-appearance: none; michael@0: min-width: 0; michael@0: min-height: 0; michael@0: background-image: linear-gradient(#505050, #575757); michael@0: border: 1px solid; michael@0: border-color: hsla(0,0%,0%,.6) hsla(0,0%,0%,.4) hsla(0,0%,0%,.4); michael@0: -moz-border-start: none; michael@0: border-radius: 0 2px 2px 0; michael@0: } michael@0: michael@0: #downloads-button[paused] > #downloads-indicator-anchor > #downloads-indicator-progress-area > #downloads-indicator-progress > .progress-bar { michael@0: background-color: rgb(220, 230, 81); michael@0: } michael@0: michael@0: #downloads-button[paused] > #downloads-indicator-anchor > #downloads-indicator-progress-area > #downloads-indicator-progress > .progress-remainder { michael@0: background-image: linear-gradient(#4b5000, #515700); michael@0: }