polymer-paper-elements-rails 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/README.md +51 -0
- data/Rakefile +1 -0
- data/app/assets/components/iron-a11y-announcer/iron-a11y-announcer.html +125 -0
- data/app/assets/components/iron-a11y-keys-behavior/iron-a11y-keys-behavior.html +418 -0
- data/app/assets/components/iron-autogrow-textarea/hero.svg +33 -0
- data/app/assets/components/iron-autogrow-textarea/iron-autogrow-textarea.html +263 -0
- data/app/assets/components/iron-behaviors/iron-button-state.html +195 -0
- data/app/assets/components/iron-behaviors/iron-control-state.html +102 -0
- data/app/assets/components/iron-fit-behavior/iron-fit-behavior.html +230 -0
- data/app/assets/components/iron-flex-layout/classes/iron-flex-layout.html +307 -0
- data/app/assets/components/iron-flex-layout/classes/iron-shadow-flex-layout.html +302 -0
- data/app/assets/components/iron-flex-layout/iron-flex-layout.html +313 -0
- data/app/assets/components/iron-form-element-behavior/iron-form-element-behavior.html +50 -0
- data/app/assets/components/iron-icon/hero.svg +19 -0
- data/app/assets/components/iron-icon/iron-icon.html +187 -0
- data/app/assets/components/iron-icons/av-icons.html +73 -0
- data/app/assets/components/iron-icons/communication-icons.html +59 -0
- data/app/assets/components/iron-icons/device-icons.html +94 -0
- data/app/assets/components/iron-icons/editor-icons.html +70 -0
- data/app/assets/components/iron-icons/hardware-icons.html +61 -0
- data/app/assets/components/iron-icons/hero.svg +35 -0
- data/app/assets/components/iron-icons/image-icons.html +164 -0
- data/app/assets/components/iron-icons/iron-icons.html +303 -0
- data/app/assets/components/iron-icons/maps-icons.html +71 -0
- data/app/assets/components/iron-icons/notification-icons.html +62 -0
- data/app/assets/components/iron-icons/social-icons.html +40 -0
- data/app/assets/components/iron-iconset-svg/iron-iconset-svg.html +191 -0
- data/app/assets/components/iron-input/hero.svg +19 -0
- data/app/assets/components/iron-input/iron-input.html +235 -0
- data/app/assets/components/iron-media-query/hero.svg +29 -0
- data/app/assets/components/iron-media-query/iron-media-query.html +84 -0
- data/app/assets/components/iron-menu-behavior/iron-menu-behavior.html +214 -0
- data/app/assets/components/iron-menu-behavior/iron-menubar-behavior.html +65 -0
- data/app/assets/components/iron-meta/hero.svg +33 -0
- data/app/assets/components/iron-meta/iron-meta.html +352 -0
- data/app/assets/components/iron-overlay-behavior/iron-overlay-backdrop.html +132 -0
- data/app/assets/components/iron-overlay-behavior/iron-overlay-behavior.html +432 -0
- data/app/assets/components/iron-overlay-behavior/iron-overlay-manager.html +107 -0
- data/app/assets/components/iron-range-behavior/iron-range-behavior.html +101 -0
- data/app/assets/components/iron-resizable-behavior/iron-resizable-behavior.html +139 -0
- data/app/assets/components/iron-selector/iron-multi-selectable.html +120 -0
- data/app/assets/components/iron-selector/iron-selectable.html +307 -0
- data/app/assets/components/iron-selector/iron-selection.html +115 -0
- data/app/assets/components/iron-selector/iron-selector.html +71 -0
- data/app/assets/components/iron-validatable-behavior/iron-validatable-behavior.html +100 -0
- data/app/assets/components/neon-animation/animations/cascaded-animation.html +84 -0
- data/app/assets/components/neon-animation/animations/fade-in-animation.html +49 -0
- data/app/assets/components/neon-animation/animations/fade-out-animation.html +49 -0
- data/app/assets/components/neon-animation/animations/hero-animation.html +83 -0
- data/app/assets/components/neon-animation/animations/opaque-animation.html +46 -0
- data/app/assets/components/neon-animation/animations/ripple-animation.html +92 -0
- data/app/assets/components/neon-animation/animations/scale-down-animation.html +65 -0
- data/app/assets/components/neon-animation/animations/scale-up-animation.html +58 -0
- data/app/assets/components/neon-animation/animations/slide-down-animation.html +59 -0
- data/app/assets/components/neon-animation/animations/slide-from-left-animation.html +60 -0
- data/app/assets/components/neon-animation/animations/slide-from-right-animation.html +60 -0
- data/app/assets/components/neon-animation/animations/slide-left-animation.html +59 -0
- data/app/assets/components/neon-animation/animations/slide-right-animation.html +59 -0
- data/app/assets/components/neon-animation/animations/slide-up-animation.html +59 -0
- data/app/assets/components/neon-animation/animations/transform-animation.html +61 -0
- data/app/assets/components/neon-animation/guides/neon-animation.md +313 -0
- data/app/assets/components/neon-animation/neon-animatable-behavior.html +156 -0
- data/app/assets/components/neon-animation/neon-animatable.html +54 -0
- data/app/assets/components/neon-animation/neon-animated-pages.html +208 -0
- data/app/assets/components/neon-animation/neon-animation-behavior.html +88 -0
- data/app/assets/components/neon-animation/neon-animation-runner-behavior.html +110 -0
- data/app/assets/components/neon-animation/neon-animation.html +17 -0
- data/app/assets/components/neon-animation/neon-animations.html +25 -0
- data/app/assets/components/neon-animation/neon-shared-element-animatable-behavior.html +37 -0
- data/app/assets/components/neon-animation/neon-shared-element-animation-behavior.html +66 -0
- data/app/assets/components/neon-animation/web-animations.html +11 -0
- data/app/assets/components/paper-behaviors/paper-button-behavior.html +55 -0
- data/app/assets/components/paper-behaviors/paper-inky-focus-behavior.html +44 -0
- data/app/assets/components/paper-button/paper-button.html +177 -0
- data/app/assets/components/paper-checkbox/metadata.html +17 -0
- data/app/assets/components/paper-checkbox/paper-checkbox.css +149 -0
- data/app/assets/components/paper-checkbox/paper-checkbox.html +163 -0
- data/app/assets/components/paper-dialog-behavior/hero.svg +51 -0
- data/app/assets/components/paper-dialog-behavior/paper-dialog-behavior.html +236 -0
- data/app/assets/components/paper-dialog-behavior/paper-dialog-common.css +58 -0
- data/app/assets/components/paper-dialog-scrollable/hero.svg +69 -0
- data/app/assets/components/paper-dialog-scrollable/paper-dialog-scrollable.html +150 -0
- data/app/assets/components/paper-dialog/hero.svg +58 -0
- data/app/assets/components/paper-dialog/paper-dialog.html +122 -0
- data/app/assets/components/paper-drawer-panel/hero.svg +21 -0
- data/app/assets/components/paper-drawer-panel/paper-drawer-panel.css +142 -0
- data/app/assets/components/paper-drawer-panel/paper-drawer-panel.html +585 -0
- data/app/assets/components/paper-fab/paper-fab.html +159 -0
- data/app/assets/components/paper-header-panel/hero.svg +38 -0
- data/app/assets/components/paper-header-panel/paper-header-panel.html +496 -0
- data/app/assets/components/paper-icon-button/paper-icon-button.html +141 -0
- data/app/assets/components/paper-input/all-imports.html +12 -0
- data/app/assets/components/paper-input/hero.svg +19 -0
- data/app/assets/components/paper-input/paper-input-addon-behavior.html +43 -0
- data/app/assets/components/paper-input/paper-input-behavior.html +293 -0
- data/app/assets/components/paper-input/paper-input-char-counter.html +95 -0
- data/app/assets/components/paper-input/paper-input-container.html +495 -0
- data/app/assets/components/paper-input/paper-input-error.html +99 -0
- data/app/assets/components/paper-input/paper-input.html +126 -0
- data/app/assets/components/paper-input/paper-textarea.html +100 -0
- data/app/assets/components/paper-item/all-imports.html +13 -0
- data/app/assets/components/paper-item/paper-icon-item.html +86 -0
- data/app/assets/components/paper-item/paper-item-body.html +93 -0
- data/app/assets/components/paper-item/paper-item-shared.css +19 -0
- data/app/assets/components/paper-item/paper-item.html +95 -0
- data/app/assets/components/paper-material/paper-material.html +98 -0
- data/app/assets/components/paper-menu/hero.svg +35 -0
- data/app/assets/components/paper-menu/paper-menu.html +133 -0
- data/app/assets/components/paper-progress/hero.svg +21 -0
- data/app/assets/components/paper-progress/paper-progress.html +199 -0
- data/app/assets/components/paper-radio-button/hero.svg +22 -0
- data/app/assets/components/paper-radio-button/paper-radio-button.css +109 -0
- data/app/assets/components/paper-radio-button/paper-radio-button.html +148 -0
- data/app/assets/components/paper-radio-group/hero.svg +25 -0
- data/app/assets/components/paper-radio-group/paper-radio-group.html +186 -0
- data/app/assets/components/paper-ripple/hero.svg +30 -0
- data/app/assets/components/paper-ripple/paper-ripple.html +714 -0
- data/app/assets/components/paper-scroll-header-panel/hero.svg +41 -0
- data/app/assets/components/paper-scroll-header-panel/paper-scroll-header-panel.html +455 -0
- data/app/assets/components/paper-slider/hero.svg +20 -0
- data/app/assets/components/paper-slider/paper-slider.css +252 -0
- data/app/assets/components/paper-slider/paper-slider.html +449 -0
- data/app/assets/components/paper-spinner/hero.svg +27 -0
- data/app/assets/components/paper-spinner/paper-spinner.css +325 -0
- data/app/assets/components/paper-spinner/paper-spinner.html +222 -0
- data/app/assets/components/paper-styles/classes/global.html +96 -0
- data/app/assets/components/paper-styles/classes/shadow-layout.html +302 -0
- data/app/assets/components/paper-styles/classes/shadow.html +39 -0
- data/app/assets/components/paper-styles/classes/typography.html +171 -0
- data/app/assets/components/paper-styles/color.html +333 -0
- data/app/assets/components/paper-styles/default-theme.html +39 -0
- data/app/assets/components/paper-styles/paper-styles-classes.html +14 -0
- data/app/assets/components/paper-styles/paper-styles.html +17 -0
- data/app/assets/components/paper-styles/shadow.html +61 -0
- data/app/assets/components/paper-styles/typography.html +240 -0
- data/app/assets/components/paper-tabs/hero.svg +23 -0
- data/app/assets/components/paper-tabs/paper-tab.html +158 -0
- data/app/assets/components/paper-tabs/paper-tabs-icons.html +18 -0
- data/app/assets/components/paper-tabs/paper-tabs.html +483 -0
- data/app/assets/components/paper-toast/hero.svg +20 -0
- data/app/assets/components/paper-toast/paper-toast.html +164 -0
- data/app/assets/components/paper-toggle-button/hero.svg +22 -0
- data/app/assets/components/paper-toggle-button/paper-toggle-button.css +108 -0
- data/app/assets/components/paper-toggle-button/paper-toggle-button.html +183 -0
- data/app/assets/components/paper-toolbar/paper-toolbar.html +375 -0
- data/app/assets/components/polymer-gestures/Gruntfile.js +60 -0
- data/app/assets/components/polymer-gestures/banner.txt +9 -0
- data/app/assets/components/polymer-gestures/build.json +17 -0
- data/app/assets/components/polymer-gestures/conf/karma.conf.js +39 -0
- data/app/assets/components/polymer-gestures/package.json +20 -0
- data/app/assets/components/polymer-gestures/polymer-gestures.html +21 -0
- data/app/assets/components/polymer-gestures/polymer-gestures.js +46 -0
- data/app/assets/components/polymer-gestures/src/dispatcher.js +474 -0
- data/app/assets/components/polymer-gestures/src/eventFactory.js +127 -0
- data/app/assets/components/polymer-gestures/src/hold.js +129 -0
- data/app/assets/components/polymer-gestures/src/mouse.js +135 -0
- data/app/assets/components/polymer-gestures/src/ms.js +80 -0
- data/app/assets/components/polymer-gestures/src/pinch.js +186 -0
- data/app/assets/components/polymer-gestures/src/platform-events.js +39 -0
- data/app/assets/components/polymer-gestures/src/pointer.js +68 -0
- data/app/assets/components/polymer-gestures/src/pointermap.js +67 -0
- data/app/assets/components/polymer-gestures/src/scope.js +10 -0
- data/app/assets/components/polymer-gestures/src/tap.js +103 -0
- data/app/assets/components/polymer-gestures/src/targetfind.js +244 -0
- data/app/assets/components/polymer-gestures/src/touch-action.js +60 -0
- data/app/assets/components/polymer-gestures/src/touch.js +341 -0
- data/app/assets/components/polymer-gestures/src/track.js +230 -0
- data/app/assets/components/web-animations-js/web-animations-next-lite.min.js +17 -0
- data/app/assets/components/web-animations-js/web-animations-next.min.js +17 -0
- data/app/assets/components/web-animations-js/web-animations.min.js +17 -0
- data/app/assets/components/webcomponentsjs/CustomElements.js +956 -0
- data/app/assets/components/webcomponentsjs/CustomElements.min.js +11 -0
- data/app/assets/components/webcomponentsjs/HTMLImports.js +1078 -0
- data/app/assets/components/webcomponentsjs/HTMLImports.min.js +11 -0
- data/app/assets/components/webcomponentsjs/MutationObserver.js +344 -0
- data/app/assets/components/webcomponentsjs/MutationObserver.min.js +11 -0
- data/app/assets/components/webcomponentsjs/ShadowDOM.js +4414 -0
- data/app/assets/components/webcomponentsjs/ShadowDOM.min.js +15 -0
- data/app/assets/components/webcomponentsjs/package.json +31 -0
- data/app/assets/components/webcomponentsjs/webcomponents-lite.js +2300 -0
- data/app/assets/components/webcomponentsjs/webcomponents-lite.min.js +13 -0
- data/app/assets/components/webcomponentsjs/webcomponents.js +7112 -0
- data/app/assets/components/webcomponentsjs/webcomponents.min.js +15 -0
- data/lib/polymer-paper-elements-rails.rb +2 -0
- data/lib/polymer-paper-elements-rails/engine.rb +4 -0
- data/lib/polymer-paper-elements-rails/version.rb +3 -0
- metadata +272 -0
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/*
|
|
2
|
+
@license
|
|
3
|
+
Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
|
|
4
|
+
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
5
|
+
The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
6
|
+
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
7
|
+
Code distributed by Google as part of the polymer project is also
|
|
8
|
+
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
:host {
|
|
12
|
+
display: block;
|
|
13
|
+
margin: 24px 40px;
|
|
14
|
+
|
|
15
|
+
background: var(--paper-dialog-background-color, --primary-background-color);
|
|
16
|
+
color: var(--paper-dialog-color, --primary-text-color);
|
|
17
|
+
|
|
18
|
+
@apply(--layout-scroll);
|
|
19
|
+
@apply(--paper-font-body1);
|
|
20
|
+
@apply(--shadow-elevation-16dp);
|
|
21
|
+
@apply(--paper-dialog);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
:host > ::content > * {
|
|
25
|
+
margin-top: 20px;
|
|
26
|
+
padding: 0 24px;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
:host > ::content > .no-padding {
|
|
30
|
+
padding: 0;
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
:host > ::content > *:first-child {
|
|
34
|
+
margin-top: 24px;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
:host > ::content > *:last-child {
|
|
38
|
+
margin-bottom: 24px;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
:host > ::content h2 {
|
|
42
|
+
position: relative;
|
|
43
|
+
margin: 0;
|
|
44
|
+
@apply(--paper-font-title);
|
|
45
|
+
|
|
46
|
+
@apply(--paper-dialog-title);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
:host > ::content .buttons {
|
|
50
|
+
position: relative;
|
|
51
|
+
padding: 8px 8px 8px 24px;
|
|
52
|
+
margin: 0;
|
|
53
|
+
|
|
54
|
+
color: var(--paper-dialog-button-color, --default-primary-color);
|
|
55
|
+
|
|
56
|
+
@apply(--layout-horizontal);
|
|
57
|
+
@apply(--layout-end-justified);
|
|
58
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
+
<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
|
3
|
+
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
|
4
|
+
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
|
5
|
+
viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve">
|
|
6
|
+
<g id="background" display="none">
|
|
7
|
+
<rect display="inline" fill="#B0BEC5" width="225" height="126"/>
|
|
8
|
+
</g>
|
|
9
|
+
<g id="label">
|
|
10
|
+
</g>
|
|
11
|
+
<g id="art">
|
|
12
|
+
<g>
|
|
13
|
+
<polygon points="0,124 0,126 2,126 "/>
|
|
14
|
+
<polygon points="0,111.6 0,114.4 11.6,126 14.4,126 "/>
|
|
15
|
+
<polygon points="0,99.1 0,101.9 24.1,126 26.9,126 "/>
|
|
16
|
+
<polygon points="0,86.6 0,89.5 36.5,126 39.4,126 "/>
|
|
17
|
+
<polygon points="0,74.2 0,77 49,126 51.8,126 "/>
|
|
18
|
+
<polygon points="0,61.7 0,64.5 61.5,126 64.3,126 "/>
|
|
19
|
+
<polygon points="0,49.2 0,52.1 73.9,126 76.8,126 "/>
|
|
20
|
+
<polygon points="0,36.8 0,39.6 86.4,126 89.2,126 "/>
|
|
21
|
+
<polygon points="76.7,101 74,101 74,98.3 0,24.3 0,27.1 98.9,126 101.7,126 "/>
|
|
22
|
+
<polygon points="74,88.7 74,85.8 0,11.8 0,14.7 "/>
|
|
23
|
+
<polygon points="89.2,101 86.3,101 111.3,126 114.2,126 "/>
|
|
24
|
+
<polygon points="101.6,101 98.8,101 123.8,126 126.6,126 "/>
|
|
25
|
+
<polygon points="74,76.2 74,73.4 0.6,0 0,0 0,2.2 "/>
|
|
26
|
+
<polygon points="114.1,101 111.3,101 136.3,126 139.1,126 "/>
|
|
27
|
+
<polygon points="74,63.7 74,60.9 13.1,0 10.3,0 "/>
|
|
28
|
+
<polygon points="74,51.3 74,48.4 25.6,0 22.7,0 "/>
|
|
29
|
+
<polygon points="126.6,101 123.7,101 148.7,126 151.6,126 "/>
|
|
30
|
+
<polygon points="74,38.8 74,36 38,0 35.2,0 "/>
|
|
31
|
+
<polygon points="139,101 136.2,101 161.2,126 164,126 "/>
|
|
32
|
+
<polygon points="74,26.3 74,25 75.5,25 50.5,0 47.7,0 "/>
|
|
33
|
+
<polygon points="150,99.5 150,101 148.7,101 173.7,126 176.5,126 "/>
|
|
34
|
+
<polygon points="150,87 150,89.9 186.1,126 189,126 "/>
|
|
35
|
+
<polygon points="85.1,25 88,25 63,0 60.1,0 "/>
|
|
36
|
+
<polygon points="150,74.6 150,77.4 198.6,126 201.4,126 "/>
|
|
37
|
+
<polygon points="97.6,25 100.4,25 75.4,0 72.6,0 "/>
|
|
38
|
+
<polygon points="150,62.1 150,64.9 211.1,126 213.9,126 "/>
|
|
39
|
+
<polygon points="110.1,25 112.9,25 87.9,0 85.1,0 "/>
|
|
40
|
+
<polygon points="150,49.7 150,52.5 223.5,126 225,126 225,124.7 "/>
|
|
41
|
+
<polygon points="122.5,25 125.3,25 100.3,0 97.5,0 "/>
|
|
42
|
+
<polygon points="112.8,0 110,0 135,25 137.8,25 "/>
|
|
43
|
+
<polygon points="150,37.2 150,40 225,115 225,112.2 "/>
|
|
44
|
+
<polygon points="125.3,0 122.5,0 147.5,25 150,25 150,27.5 225,102.5 225,99.7 "/>
|
|
45
|
+
<polygon points="137.7,0 134.9,0 225,90.1 225,87.3 "/>
|
|
46
|
+
<polygon points="150.2,0 147.4,0 225,77.6 225,74.8 "/>
|
|
47
|
+
<polygon points="162.7,0 159.8,0 225,65.2 225,62.3 "/>
|
|
48
|
+
<polygon points="175.1,0 172.3,0 225,52.7 225,49.9 "/>
|
|
49
|
+
<polygon points="187.6,0 184.8,0 225,40.2 225,37.4 "/>
|
|
50
|
+
<polygon points="200.1,0 197.2,0 225,27.8 225,24.9 "/>
|
|
51
|
+
<polygon points="212.5,0 209.7,0 225,15.3 225,12.5 "/>
|
|
52
|
+
<polygon points="225,0 222.2,0 225,2.8 225,0 "/>
|
|
53
|
+
</g>
|
|
54
|
+
<path d="M151,102H73V24h78V102z M75,100h74V26H75V100z"/>
|
|
55
|
+
<rect x="82" y="53" width="26" height="2"/>
|
|
56
|
+
<rect x="116" y="53" width="26" height="2"/>
|
|
57
|
+
<rect x="82" y="62" width="26" height="2"/>
|
|
58
|
+
<rect x="82" y="72" width="26" height="2"/>
|
|
59
|
+
<rect x="116" y="72" width="26" height="2"/>
|
|
60
|
+
<rect x="82" y="42" width="26" height="2"/>
|
|
61
|
+
<circle cx="120" cy="63" r="4"/>
|
|
62
|
+
<circle cx="134" cy="63" r="4"/>
|
|
63
|
+
<rect x="116" y="85" width="22" height="5.5"/>
|
|
64
|
+
<g id="ic_x5F_add_x0D_">
|
|
65
|
+
</g>
|
|
66
|
+
</g>
|
|
67
|
+
<g id="Guides">
|
|
68
|
+
</g>
|
|
69
|
+
</svg>
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
@license
|
|
3
|
+
Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
|
|
4
|
+
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
5
|
+
The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
6
|
+
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
7
|
+
Code distributed by Google as part of the polymer project is also
|
|
8
|
+
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
9
|
+
-->
|
|
10
|
+
|
|
11
|
+
<link rel="import" href="../polymer/polymer.html">
|
|
12
|
+
<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html">
|
|
13
|
+
<link rel="import" href="../paper-styles/paper-styles.html">
|
|
14
|
+
|
|
15
|
+
<!--
|
|
16
|
+
`paper-dialog-scrollable` implements a scrolling area used in a Material Design dialog. It shows
|
|
17
|
+
a divider at the top and/or bottom indicating more content, depending on scroll position. Use this
|
|
18
|
+
together with elements implementing `Polymer.PaperDialogBehavior`.
|
|
19
|
+
|
|
20
|
+
<paper-dialog-impl>
|
|
21
|
+
<h2>Header</h2>
|
|
22
|
+
<paper-dialog-scrollable>
|
|
23
|
+
Lorem ipsum...
|
|
24
|
+
</paper-dialog-scrollable>
|
|
25
|
+
<div class="buttons">
|
|
26
|
+
<paper-button>OK</paper-button>
|
|
27
|
+
</div>
|
|
28
|
+
</paper-dialog-impl>
|
|
29
|
+
|
|
30
|
+
It shows a top divider after scrolling if it is not the first child in its parent container,
|
|
31
|
+
indicating there is more content above. It shows a bottom divider if it is scrollable and it is not
|
|
32
|
+
the last child in its parent container, indicating there is more content below. The bottom divider
|
|
33
|
+
is hidden if it is scrolled to the bottom.
|
|
34
|
+
|
|
35
|
+
@group Paper Elements
|
|
36
|
+
@element paper-dialog-scrollable
|
|
37
|
+
@demo demo/index.html
|
|
38
|
+
@hero hero.svg
|
|
39
|
+
-->
|
|
40
|
+
|
|
41
|
+
<dom-module id="paper-dialog-scrollable">
|
|
42
|
+
|
|
43
|
+
<style>
|
|
44
|
+
|
|
45
|
+
:host {
|
|
46
|
+
display: block;
|
|
47
|
+
position: relative;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
:host(.is-scrolled:not(:first-child))::before {
|
|
51
|
+
content: '';
|
|
52
|
+
position: absolute;
|
|
53
|
+
top: 0;
|
|
54
|
+
left: 0;
|
|
55
|
+
right: 0;
|
|
56
|
+
height: 1px;
|
|
57
|
+
background: var(--divider-color);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
:host(.can-scroll:not(.scrolled-to-bottom):not(:last-child))::after {
|
|
61
|
+
content: '';
|
|
62
|
+
position: absolute;
|
|
63
|
+
bottom: 0;
|
|
64
|
+
left: 0;
|
|
65
|
+
right: 0;
|
|
66
|
+
height: 1px;
|
|
67
|
+
background: var(--divider-color);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.scrollable {
|
|
71
|
+
padding: 0 24px;
|
|
72
|
+
|
|
73
|
+
@apply(--layout-scroll);
|
|
74
|
+
|
|
75
|
+
@apply(--paper-dialog-scrollable);
|
|
76
|
+
}
|
|
77
|
+
</style>
|
|
78
|
+
|
|
79
|
+
<template>
|
|
80
|
+
<div id="scrollable" class="scrollable">
|
|
81
|
+
<content></content>
|
|
82
|
+
</div>
|
|
83
|
+
</template>
|
|
84
|
+
|
|
85
|
+
</dom-module>
|
|
86
|
+
|
|
87
|
+
<script>
|
|
88
|
+
|
|
89
|
+
(function() {
|
|
90
|
+
|
|
91
|
+
Polymer({
|
|
92
|
+
|
|
93
|
+
is: 'paper-dialog-scrollable',
|
|
94
|
+
|
|
95
|
+
properties: {
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* The dialog element that implements `Polymer.PaperDialogBehavior` containing this element.
|
|
99
|
+
*/
|
|
100
|
+
dialogElement: {
|
|
101
|
+
type: Object,
|
|
102
|
+
value: function() {
|
|
103
|
+
return this.parentNode;
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
},
|
|
108
|
+
|
|
109
|
+
listeners: {
|
|
110
|
+
'scrollable.scroll': '_onScroll',
|
|
111
|
+
'iron-resize': '_onIronResize'
|
|
112
|
+
},
|
|
113
|
+
|
|
114
|
+
/**
|
|
115
|
+
* Returns the scrolling element.
|
|
116
|
+
*/
|
|
117
|
+
get scrollTarget() {
|
|
118
|
+
return this.$.scrollable;
|
|
119
|
+
},
|
|
120
|
+
|
|
121
|
+
attached: function() {
|
|
122
|
+
this.classList.add('no-padding');
|
|
123
|
+
// Set itself to the overlay sizing target
|
|
124
|
+
this.dialogElement.sizingTarget = this.scrollTarget;
|
|
125
|
+
// If the host is sized, fit the scrollable area to the container. Otherwise let it be
|
|
126
|
+
// its natural size.
|
|
127
|
+
requestAnimationFrame(function() {
|
|
128
|
+
if (this.offsetHeight > 0) {
|
|
129
|
+
this.$.scrollable.classList.add('fit');
|
|
130
|
+
}
|
|
131
|
+
this._scroll();
|
|
132
|
+
}.bind(this));
|
|
133
|
+
},
|
|
134
|
+
|
|
135
|
+
_scroll: function() {
|
|
136
|
+
this.toggleClass('is-scrolled', this.scrollTarget.scrollTop > 0);
|
|
137
|
+
this.toggleClass('can-scroll', this.scrollTarget.offsetHeight < this.scrollTarget.scrollHeight);
|
|
138
|
+
this.toggleClass('scrolled-to-bottom',
|
|
139
|
+
this.scrollTarget.scrollTop + this.scrollTarget.offsetHeight >= this.scrollTarget.scrollHeight);
|
|
140
|
+
},
|
|
141
|
+
|
|
142
|
+
_onScroll: function() {
|
|
143
|
+
this._scroll();
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
})
|
|
147
|
+
|
|
148
|
+
})();
|
|
149
|
+
|
|
150
|
+
</script>
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
+
<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
|
3
|
+
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
|
4
|
+
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
|
5
|
+
viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve">
|
|
6
|
+
<g id="background" display="none">
|
|
7
|
+
<rect display="inline" fill="#B0BEC5" width="225" height="126"/>
|
|
8
|
+
</g>
|
|
9
|
+
<g id="label">
|
|
10
|
+
</g>
|
|
11
|
+
<g id="art">
|
|
12
|
+
<g>
|
|
13
|
+
<polygon points="0,124 0,126 2,126 "/>
|
|
14
|
+
<polygon points="0,111.6 0,114.4 11.6,126 14.4,126 "/>
|
|
15
|
+
<polygon points="0,99.1 0,101.9 24.1,126 26.9,126 "/>
|
|
16
|
+
<polygon points="0,86.6 0,89.5 36.5,126 39.4,126 "/>
|
|
17
|
+
<polygon points="0,74.2 0,77 49,126 51.8,126 "/>
|
|
18
|
+
<polygon points="0,61.7 0,64.5 61.5,126 64.3,126 "/>
|
|
19
|
+
<polygon points="0,49.2 0,52.1 73.9,126 76.8,126 "/>
|
|
20
|
+
<polygon points="0,36.8 0,39.6 86.4,126 89.2,126 "/>
|
|
21
|
+
<polygon points="0,24.3 0,27.1 98.9,126 101.7,126 "/>
|
|
22
|
+
<polygon points="75.2,87 74,87 74,85.8 0,11.8 0,14.7 111.3,126 114.2,126 "/>
|
|
23
|
+
<polygon points="87.6,87 84.8,87 123.8,126 126.6,126 "/>
|
|
24
|
+
<polygon points="74,76.2 74,73.4 0.6,0 0,0 0,2.2 "/>
|
|
25
|
+
<polygon points="74,63.7 74,60.9 13.1,0 10.3,0 "/>
|
|
26
|
+
<polygon points="100.1,87 97.3,87 136.3,126 139.1,126 "/>
|
|
27
|
+
<polygon points="112.6,87 109.7,87 148.7,126 151.6,126 "/>
|
|
28
|
+
<polygon points="74,51.3 74,48.4 25.6,0 22.7,0 "/>
|
|
29
|
+
<polygon points="125,87 122.2,87 161.2,126 164,126 "/>
|
|
30
|
+
<polygon points="74.2,39 77,39 38,0 35.2,0 "/>
|
|
31
|
+
<polygon points="86.7,39 89.5,39 50.5,0 47.7,0 "/>
|
|
32
|
+
<polygon points="137.5,87 134.7,87 173.7,126 176.5,126 "/>
|
|
33
|
+
<polygon points="150,87 147.1,87 186.1,126 189,126 "/>
|
|
34
|
+
<polygon points="99.1,39 102,39 63,0 60.1,0 "/>
|
|
35
|
+
<polygon points="150,74.6 150,77.4 198.6,126 201.4,126 "/>
|
|
36
|
+
<polygon points="111.6,39 114.4,39 75.4,0 72.6,0 "/>
|
|
37
|
+
<polygon points="150,62.1 150,64.9 211.1,126 213.9,126 "/>
|
|
38
|
+
<polygon points="124.1,39 126.9,39 87.9,0 85.1,0 "/>
|
|
39
|
+
<polygon points="100.3,0 97.5,0 136.5,39 139.3,39 "/>
|
|
40
|
+
<polygon points="150,49.7 150,52.5 223.5,126 225,126 225,124.7 "/>
|
|
41
|
+
<polygon points="112.8,0 110,0 149,39 150,39 150,40 225,115 225,112.2 "/>
|
|
42
|
+
<polygon points="125.3,0 122.5,0 225,102.5 225,99.7 "/>
|
|
43
|
+
<polygon points="137.7,0 134.9,0 225,90.1 225,87.3 "/>
|
|
44
|
+
<polygon points="150.2,0 147.4,0 225,77.6 225,74.8 "/>
|
|
45
|
+
<polygon points="162.7,0 159.8,0 225,65.2 225,62.3 "/>
|
|
46
|
+
<polygon points="175.1,0 172.3,0 225,52.7 225,49.9 "/>
|
|
47
|
+
<polygon points="187.6,0 184.8,0 225,40.2 225,37.4 "/>
|
|
48
|
+
<polygon points="200.1,0 197.2,0 225,27.8 225,24.9 "/>
|
|
49
|
+
<polygon points="212.5,0 209.7,0 225,15.3 225,12.5 "/>
|
|
50
|
+
<polygon points="225,0 222.2,0 225,2.8 225,0 "/>
|
|
51
|
+
</g>
|
|
52
|
+
<g id="ic_x5F_add_x0D_">
|
|
53
|
+
</g>
|
|
54
|
+
<path d="M151,88H73V38h78V88z M75,86h74V40H75V86z"/>
|
|
55
|
+
</g>
|
|
56
|
+
<g id="Guides">
|
|
57
|
+
</g>
|
|
58
|
+
</svg>
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
@license
|
|
3
|
+
Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
|
|
4
|
+
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
5
|
+
The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
6
|
+
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
7
|
+
Code distributed by Google as part of the polymer project is also
|
|
8
|
+
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
9
|
+
-->
|
|
10
|
+
|
|
11
|
+
<link rel="import" href="../polymer/polymer.html">
|
|
12
|
+
<link rel="import" href="../neon-animation/neon-animation-runner-behavior.html">
|
|
13
|
+
<link rel="import" href="../paper-dialog-behavior/paper-dialog-behavior.html">
|
|
14
|
+
<link rel="import" href="../paper-styles/paper-styles.html">
|
|
15
|
+
|
|
16
|
+
<!--
|
|
17
|
+
`<paper-dialog>` is a dialog with Material Design styling and optional animations when it is
|
|
18
|
+
opened or closed. It provides styles for a header, content area, and an action area for buttons.
|
|
19
|
+
You can use the `<paper-dialog-scrollable` element (in its own repository) if you need a scrolling
|
|
20
|
+
content area. See `Polymer.PaperDialogBehavior` for specifics.
|
|
21
|
+
|
|
22
|
+
For example, the following code implements a dialog with a header, scrolling content area and
|
|
23
|
+
buttons.
|
|
24
|
+
|
|
25
|
+
<paper-dialog>
|
|
26
|
+
<h2>Header</h2>
|
|
27
|
+
<paper-dialog-scrollable>
|
|
28
|
+
Lorem ipsum...
|
|
29
|
+
</paper-dialog-scrollable>
|
|
30
|
+
<div class="buttons">
|
|
31
|
+
<paper-button dialog-dismiss>Cancel</paper-button>
|
|
32
|
+
<paper-button dialog-confirm>Accept</paper-button>
|
|
33
|
+
</div>
|
|
34
|
+
</paper-dialog>
|
|
35
|
+
|
|
36
|
+
### Styling
|
|
37
|
+
|
|
38
|
+
See the docs for `Polymer.PaperDialogBehavior` for the custom properties available for styling
|
|
39
|
+
this element.
|
|
40
|
+
|
|
41
|
+
### Animations
|
|
42
|
+
|
|
43
|
+
Set the `entry-animation` and/or `exit-animation` attributes to add an animation when the dialog
|
|
44
|
+
is opened or closed. See the documentation in
|
|
45
|
+
[PolymerElements/neon-animation](https://github.com/PolymerElements/neon-animation) for more info.
|
|
46
|
+
|
|
47
|
+
For example:
|
|
48
|
+
|
|
49
|
+
<link rel="import" href="components/neon-animation/animations/scale-up-animation.html">
|
|
50
|
+
<link rel="import" href="components/neon-animation/animations/fade-out-animation.html">
|
|
51
|
+
|
|
52
|
+
<paper-dialog entry-animation="scale-up-animation"
|
|
53
|
+
exit-animation="fade-out-animation">
|
|
54
|
+
<h2>Header</h2>
|
|
55
|
+
<div>Dialog body</div>
|
|
56
|
+
</paper-dialog>
|
|
57
|
+
|
|
58
|
+
### Accessibility
|
|
59
|
+
|
|
60
|
+
See the docs for `Polymer.PaperDialogBehavior` for accessibility features implemented by this
|
|
61
|
+
element.
|
|
62
|
+
|
|
63
|
+
@group Paper Elements
|
|
64
|
+
@element paper-dialog
|
|
65
|
+
@hero hero.svg
|
|
66
|
+
@demo demo/index.html
|
|
67
|
+
-->
|
|
68
|
+
|
|
69
|
+
<dom-module id="paper-dialog">
|
|
70
|
+
|
|
71
|
+
<link rel="import" type="css" href="../paper-dialog-behavior/paper-dialog-common.css">
|
|
72
|
+
|
|
73
|
+
<template>
|
|
74
|
+
<content></content>
|
|
75
|
+
</template>
|
|
76
|
+
|
|
77
|
+
</dom-module>
|
|
78
|
+
|
|
79
|
+
<script>
|
|
80
|
+
|
|
81
|
+
(function() {
|
|
82
|
+
|
|
83
|
+
Polymer({
|
|
84
|
+
|
|
85
|
+
is: 'paper-dialog',
|
|
86
|
+
|
|
87
|
+
behaviors: [
|
|
88
|
+
Polymer.PaperDialogBehavior,
|
|
89
|
+
Polymer.NeonAnimationRunnerBehavior
|
|
90
|
+
],
|
|
91
|
+
|
|
92
|
+
listeners: {
|
|
93
|
+
'neon-animation-finish': '_onNeonAnimationFinish'
|
|
94
|
+
},
|
|
95
|
+
|
|
96
|
+
_renderOpened: function() {
|
|
97
|
+
if (this.withBackdrop) {
|
|
98
|
+
this.backdropElement.open();
|
|
99
|
+
}
|
|
100
|
+
this.playAnimation('entry');
|
|
101
|
+
},
|
|
102
|
+
|
|
103
|
+
_renderClosed: function() {
|
|
104
|
+
if (this.withBackdrop) {
|
|
105
|
+
this.backdropElement.close();
|
|
106
|
+
}
|
|
107
|
+
this.playAnimation('exit');
|
|
108
|
+
},
|
|
109
|
+
|
|
110
|
+
_onNeonAnimationFinish: function() {
|
|
111
|
+
if (this.opened) {
|
|
112
|
+
this._finishRenderOpened();
|
|
113
|
+
} else {
|
|
114
|
+
this._finishRenderClosed();
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
});
|
|
119
|
+
|
|
120
|
+
})();
|
|
121
|
+
|
|
122
|
+
</script>
|