@shortfuse/materialdesignweb 0.7.1-0 → 0.7.1-2

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.
Files changed (138) hide show
  1. package/bin/generate-css.js +1 -2
  2. package/components/Badge.js +40 -3
  3. package/components/Body.js +16 -2
  4. package/components/BottomAppBar.js +25 -2
  5. package/components/Box.js +33 -3
  6. package/components/Button.js +146 -9
  7. package/components/Card.js +111 -3
  8. package/components/Checkbox.js +91 -3
  9. package/components/CheckboxIcon.js +92 -4
  10. package/components/Chip.js +38 -2
  11. package/components/Dialog.js +237 -3
  12. package/components/DialogActions.js +3 -2
  13. package/components/Divider.js +44 -3
  14. package/components/ExtendedFab.js +27 -2
  15. package/components/Fab.js +26 -2
  16. package/components/FilterChip.js +83 -2
  17. package/components/Headline.js +16 -2
  18. package/components/Icon.js +80 -4
  19. package/components/IconButton.js +153 -2
  20. package/components/Label.js +16 -2
  21. package/components/Layout.js +21 -3
  22. package/components/List.js +15 -2
  23. package/components/ListItem.js +229 -3
  24. package/components/ListOption.js +37 -3
  25. package/components/ListSelect.js +12 -2
  26. package/components/Menu.js +173 -3
  27. package/components/MenuItem.js +55 -2
  28. package/components/Nav.js +19 -2
  29. package/components/NavBar.js +37 -2
  30. package/components/NavBarItem.js +44 -2
  31. package/components/NavDrawer.js +34 -2
  32. package/components/NavDrawerItem.js +44 -2
  33. package/components/NavItem.js +183 -3
  34. package/components/NavRail.js +50 -2
  35. package/components/NavRailItem.js +25 -2
  36. package/components/Pane.js +263 -3
  37. package/components/Progress.js +469 -10
  38. package/components/Radio.js +97 -3
  39. package/components/RadioIcon.js +77 -5
  40. package/components/Ripple.js +76 -3
  41. package/components/SegmentedButton.js +97 -2
  42. package/components/SegmentedButtonGroup.js +15 -2
  43. package/components/Select.js +54 -2
  44. package/components/Shape.js +55 -18
  45. package/components/Slider.js +309 -3
  46. package/components/Snackbar.js +82 -2
  47. package/components/Surface.js +13 -4
  48. package/components/Switch.js +67 -4
  49. package/components/SwitchIcon.js +272 -5
  50. package/components/Tab.js +87 -3
  51. package/components/TabContent.js +21 -21
  52. package/components/TabList.js +131 -2
  53. package/components/TextArea.js +97 -3
  54. package/components/Title.js +16 -2
  55. package/components/Tooltip.js +42 -2
  56. package/components/TopAppBar.js +212 -3
  57. package/core/template.js +36 -9
  58. package/mixins/ControlMixin.js +65 -2
  59. package/mixins/DensityMixin.js +17 -3
  60. package/mixins/FlexableMixin.js +81 -3
  61. package/mixins/RippleMixin.js +15 -4
  62. package/mixins/ShapeMixin.js +279 -8
  63. package/mixins/StateMixin.js +87 -5
  64. package/mixins/SurfaceMixin.js +152 -3
  65. package/mixins/TextFieldMixin.js +661 -3
  66. package/mixins/ThemableMixin.js +206 -3
  67. package/mixins/TooltipTriggerMixin.js +30 -4
  68. package/mixins/TouchTargetMixin.js +29 -4
  69. package/package.json +2 -1
  70. package/theming/loader.js +0 -2
  71. package/components/Badge.css +0 -38
  72. package/components/Body.css +0 -14
  73. package/components/BottomAppBar.css +0 -23
  74. package/components/Box.css +0 -31
  75. package/components/Button.css +0 -147
  76. package/components/Card.css +0 -109
  77. package/components/Checkbox.css +0 -89
  78. package/components/CheckboxIcon.css +0 -90
  79. package/components/Chip.css +0 -35
  80. package/components/Dialog.css +0 -235
  81. package/components/Divider.css +0 -41
  82. package/components/ExtendedFab.css +0 -24
  83. package/components/Fab.css +0 -23
  84. package/components/FilterChip.css +0 -80
  85. package/components/Headline.css +0 -14
  86. package/components/Icon.css +0 -76
  87. package/components/IconButton.css +0 -150
  88. package/components/Label.css +0 -14
  89. package/components/Layout.css +0 -19
  90. package/components/List.css +0 -12
  91. package/components/ListItem.css +0 -224
  92. package/components/ListOption.css +0 -34
  93. package/components/ListSelect.css +0 -9
  94. package/components/Menu.css +0 -171
  95. package/components/MenuItem.css +0 -53
  96. package/components/Nav.css +0 -17
  97. package/components/NavBar.css +0 -34
  98. package/components/NavBarItem.css +0 -41
  99. package/components/NavDrawer.css +0 -31
  100. package/components/NavDrawerItem.css +0 -42
  101. package/components/NavItem.css +0 -181
  102. package/components/NavRail.css +0 -47
  103. package/components/NavRailItem.css +0 -25
  104. package/components/Outline.css +0 -138
  105. package/components/Pane.css +0 -261
  106. package/components/Progress.css +0 -75
  107. package/components/ProgressCircle.css +0 -226
  108. package/components/ProgressLine.css +0 -155
  109. package/components/Radio.css +0 -95
  110. package/components/RadioIcon.css +0 -73
  111. package/components/Ripple.css +0 -74
  112. package/components/SegmentedButton.css +0 -94
  113. package/components/SegmentedButtonGroup.css +0 -12
  114. package/components/Select.css +0 -52
  115. package/components/Shape.css +0 -132
  116. package/components/Slider.css +0 -307
  117. package/components/Snackbar.css +0 -80
  118. package/components/Surface.css +0 -10
  119. package/components/Switch.css +0 -64
  120. package/components/SwitchIcon.css +0 -178
  121. package/components/SwitchIconAnimations.css +0 -89
  122. package/components/Tab.css +0 -85
  123. package/components/TabList.css +0 -129
  124. package/components/TextArea.css +0 -93
  125. package/components/Title.css +0 -14
  126. package/components/Tooltip.css +0 -40
  127. package/components/TopAppBar.css +0 -209
  128. package/mixins/ControlMixin.css +0 -57
  129. package/mixins/DensityMixin.css +0 -40
  130. package/mixins/FlexableMixin.css +0 -79
  131. package/mixins/RippleMixin.css +0 -12
  132. package/mixins/ShapeMixin.css +0 -135
  133. package/mixins/StateMixin.css +0 -82
  134. package/mixins/SurfaceMixin.css +0 -150
  135. package/mixins/TextFieldMixin.css +0 -657
  136. package/mixins/ThemableMixin.css +0 -204
  137. package/mixins/TooltipTriggerMixin.css +0 -27
  138. package/mixins/TouchTargetMixin.css +0 -26
@@ -1,34 +0,0 @@
1
- /* https://m3.material.io/components/navigation-bar/specs */
2
-
3
- :host {
4
- position: sticky;
5
- inset-block-end: 0;
6
- order:1; /* Nav Bars are at top of tab order, but bottom of page */
7
-
8
- display: grid;
9
- align-content: flex-start;
10
- align-items: flex-start;
11
- gap: 8px;
12
- grid-auto-columns: minmax(48px, 1fr);
13
- grid-auto-flow: column;
14
-
15
- overflow: hidden; /* Don't expand viewport when contents translates */
16
-
17
- box-sizing: border-box;
18
- min-block-size: 80px;
19
- inline-size: 100%;
20
-
21
- flex-shrink: 0;
22
-
23
- transform: translateY(0);
24
-
25
- box-shadow: none;
26
-
27
- text-align: center;
28
-
29
- will-change: transform;
30
- }
31
-
32
- #slot {
33
- pointer-events: auto;
34
- }
@@ -1,41 +0,0 @@
1
- /* https://m3.material.io/components/navigation-bar/specs */
2
- /* https://m3.material.io/components/navigation-drawer/specs */
3
- /* https://m3.material.io/components/navigation-rail/specs */
4
-
5
- :host {
6
- grid-auto-rows: minmax(20px, min-content);
7
- grid-template-rows: [icon] minmax(32px, 1fr);
8
- grid-template-columns: auto [icon] minmax(56px, 1fr) auto;
9
-
10
- padding-block: 12px; /* Spec 16px bottom is based on 1em not 1lh */
11
- }
12
-
13
- #slot {
14
- display: block;
15
- }
16
-
17
- :host(:empty) {
18
- font-size: 0;
19
- line-height: 0;
20
- }
21
-
22
- #slot[show-label] {
23
- grid-column: 1 /4;
24
-
25
- grid-row: 2;
26
-
27
- opacity: 0;
28
- }
29
-
30
- #shape {
31
- grid-column: 2;
32
- grid-row: 1 / 1;
33
- }
34
-
35
- #slot[show-label="never"] {
36
- block-size: 0;
37
- }
38
-
39
- #slot[show-label="active"][active] {
40
- opacity: 1;
41
- }
@@ -1,31 +0,0 @@
1
- /* https://m3.material.io/components/navigation-drawer/specs */
2
-
3
- :host([open]) {
4
- --mdw-surface__tint: var(--mdw-surface__tint__0);
5
- --mdw-surface__tint__raised: var(--mdw-surface__tint__1);
6
- --mdw-shape__size: var(--mdw-shape__large, 16px);
7
- --mdw-shape__size__top-start-size: 0px;
8
- --mdw-shape__size__bottom-start-size: 0px;
9
-
10
- --mdw-nav-item__badge__position: static;
11
- --mdw-nav-item__badge__transform: none;
12
- --mdw-nav-item__badge__grid-area: badge;
13
- --mdw-nav-item__label__padding-block: 18px;
14
- --mdw-nav-item__label__padding-inline: 52px 0;
15
- --mdw-nav-item__anchor__display: block;
16
- --mdw-nav-item__indicator__grid-area: auto;
17
-
18
- display: block;
19
- grid-template-rows: min-content;
20
- grid-template-columns: minmax(360px, min-content);
21
-
22
- min-inline-size: 360px;
23
- padding-inline: 12px;
24
-
25
- box-shadow: none;
26
-
27
- }
28
-
29
- #slot {
30
- gap: 0;
31
- }
@@ -1,42 +0,0 @@
1
- /* https://m3.material.io/components/navigation-bar/specs */
2
- /* https://m3.material.io/components/navigation-drawer/specs */
3
- /* https://m3.material.io/components/navigation-rail/specs */
4
-
5
- :host {
6
- align-self: stretch;
7
-
8
- display: grid;
9
- display: flex;
10
- align-items: center;
11
- gap: 12px;
12
- grid-template:
13
- "icon label badge" minmax(56px, min-content)
14
- / 24px 1fr minmax(0, min-content);
15
- justify-items: flex-start;
16
-
17
- padding-inline: 16px 24px;
18
- }
19
-
20
- #icon {
21
- grid-area: icon;
22
- }
23
-
24
- #slot {
25
- display: block;
26
-
27
- text-align: start;
28
- }
29
-
30
- :host([active]) {
31
- color: rgb(var(--mdw-ink));
32
- }
33
-
34
- #shape {
35
- max-inline-size: none;
36
- grid-column: auto;
37
- grid-row: 1 / 2;
38
- }
39
-
40
- #badge-text {
41
- z-index: 1;
42
- }
@@ -1,181 +0,0 @@
1
- /* https://m3.material.io/components/navigation-bar/specs */
2
- /* https://m3.material.io/components/navigation-drawer/specs */
3
- /* https://m3.material.io/components/navigation-rail/specs */
4
-
5
- :host {
6
- --mdw-badge__scale: 0;
7
- --mdw-shape__size: var(--mdw-shape__full);
8
- --mdw-nav-item__offset-y: 0;
9
- position: relative;
10
-
11
- display: grid;
12
- align-content: center;
13
- align-items: center;
14
- grid-auto-flow: row;
15
- grid-auto-rows: minmax(20px, min-content);
16
- grid-template-rows: [icon] minmax(32px, 1fr);
17
- grid-template-columns: [icon] minmax(56px, 1fr);
18
-
19
- justify-items: center;
20
- row-gap: 4px;
21
-
22
- box-sizing: border-box;
23
- min-block-size: 56px;
24
-
25
- padding-inline: 0;
26
-
27
- cursor: pointer;
28
- /* stylelint-disable-next-line plugin/no-unsupported-browser-features */
29
- user-select: none;
30
-
31
- font: var(--mdw-typescale__label-large__font);
32
- letter-spacing: var(--mdw-typescale__label-large__letter-spacing);
33
-
34
- text-align: center;
35
- }
36
-
37
- :host(:not([color])) {
38
- --mdw-ink: var(--mdw-color__on-secondary-container);
39
- --mdw-bg: var(--mdw-color__secondary-container);
40
- }
41
-
42
- :host([color]) {
43
- background-color: transparent;
44
- color: rgb(var(--mdw-color__on-surface-variant));
45
- }
46
-
47
- #slot {
48
- display: contents;
49
- align-items: center;
50
- flex-direction: column;
51
- grid-area: label;
52
- justify-content: center;
53
-
54
- grid-column: 1 /4;
55
-
56
- grid-row: 2;
57
-
58
- flex: 1;
59
-
60
- cursor: inherit;
61
- outline: none;
62
-
63
- transform: translateY(var(--mdw-nav-item__offset-y));
64
-
65
- color: rgb(var(--mdw-color__on-surface-variant));
66
-
67
- transition: opacity, color, transform 200ms;
68
- will-change: opacity, transform;
69
- }
70
-
71
- #anchor {
72
- position: absolute;
73
- inset: 0;
74
- }
75
-
76
- #shape {
77
- position: absolute;
78
- /* stylelint-disable-next-line liberty/use-logical-spec */
79
- top: 50%;
80
- /* stylelint-disable-next-line liberty/use-logical-spec */
81
- left: 50%;
82
-
83
- block-size: 100%;
84
- inline-size: 100%;
85
- max-inline-size: 56px;
86
-
87
- grid-column: icon;
88
- grid-row: 1 / 1;
89
-
90
- transform: translateX(-50%) translateY(-50%) translateY(var(--mdw-nav-item__offset-y));
91
- z-index: 0;
92
-
93
- background-color: transparent;
94
-
95
- transition: transform 200ms;
96
- will-change: transform;
97
- }
98
-
99
- #icon {
100
- position: relative;
101
- align-self: center;
102
-
103
- grid-area: icon;
104
-
105
- transform: translateY(var(--mdw-nav-item__offset-y));
106
- z-index: 3;
107
-
108
- color: rgb(var(--mdw-color__on-surface-variant));
109
-
110
- font-size: 24px;
111
- font-variation-settings: 'FILL' 0;
112
-
113
- transition: transform 200ms;
114
- will-change: transform;
115
- }
116
-
117
- #state {
118
- z-index: 2;
119
- }
120
-
121
- #badge {
122
- --mdw-badge__scale: 0;
123
- position: absolute;
124
- inset-block-start: 50%;
125
- inset-inline-start: 50%;
126
-
127
- overflow: hidden;
128
-
129
- max-inline-size: 50%;
130
- grid-column: 1 / 4;
131
-
132
- grid-row: 1 / 2;
133
-
134
- transform: translateY(-100%) translateY(var(--mdw-nav-item__offset-y)) scale(var(--mdw-badge__scale));
135
- z-index: 4;
136
-
137
- text-align: start;
138
- text-overflow: ellipsis;
139
- text-transform: none;
140
- white-space: nowrap;
141
- word-break: normal;
142
-
143
- transition: transform 200ms;
144
- will-change: transform;
145
- }
146
-
147
- #badge[badge] {
148
- --mdw-badge__scale: 1;
149
- }
150
-
151
- #ripple {
152
- opacity: 1;
153
-
154
- color: rgb(var(--mdw-bg));
155
- }
156
-
157
- #ripple-container {
158
- z-index:1;
159
- }
160
-
161
- #shape[active] {
162
- color: rgb(var(--mdw-ink));
163
- }
164
-
165
- #icon[active] {
166
- color: rgb(var(--mdw-ink));
167
-
168
- font-variation-settings: 'FILL' 1;
169
- }
170
-
171
- #slot[active] {
172
- color: inherit;
173
- }
174
-
175
- :host([show-label]) {
176
- --mdw-nav-item__offset-y: 12px;
177
- }
178
-
179
- :host([show-label="active"][active]) {
180
- --mdw-nav-item__offset-y: 0;
181
- }
@@ -1,47 +0,0 @@
1
- /* https://m3.material.io/components/navigation-rail/specs */
2
-
3
- :host{
4
- display: grid;
5
- align-content: flex-start;
6
- flex-direction: column;
7
- grid-template-rows: auto minmax(0,1fr);
8
- grid-template-columns: 80px;
9
- justify-items: stretch;
10
-
11
- text-align: center;
12
- }
13
-
14
- #start {
15
- display: flex;
16
- align-items: center;
17
- flex-direction: column;
18
- gap: 12px;
19
-
20
- padding-block-start: 12px;
21
-
22
- }
23
-
24
- #slot {
25
- align-self: center;
26
-
27
- display: flex;
28
- align-items: stretch;
29
- flex-direction: column;
30
- gap: 12px;
31
- overflow-x: clip;
32
- overflow-y: auto;
33
-
34
- box-sizing: border-box;
35
-
36
- inline-size: 100%;
37
-
38
- padding-block: 12px;
39
- }
40
-
41
- #slot[align="start"] {
42
- align-self: flex-start;
43
- }
44
-
45
- #slot[align="end"] {
46
- align-self: flex-end;
47
- }
@@ -1,25 +0,0 @@
1
- /* https://m3.material.io/components/navigation-bar/specs */
2
- /* https://m3.material.io/components/navigation-drawer/specs */
3
- /* https://m3.material.io/components/navigation-rail/specs */
4
-
5
- :host {
6
- grid-auto-flow: row;
7
- grid-auto-rows: minmax(20px, min-content);
8
- grid-template-rows: [icon] minmax(32px, 1fr);
9
- grid-template-columns: [icon] minmax(56px, 1fr);
10
-
11
- padding-inline: 12px;
12
- }
13
-
14
- #slot {
15
- display: contents;
16
- overflow-wrap: anywhere;
17
-
18
- word-break: break-all;
19
- word-break: break-word;
20
- }
21
-
22
- #badge {
23
- max-inline-size:40px;
24
- grid-column: 1 / 2;
25
- }
@@ -1,138 +0,0 @@
1
- .outline {
2
- position: absolute;
3
- inset: 0;
4
-
5
- pointer-events: none;
6
-
7
- border-color: currentColor;
8
- border-radius: inherit;
9
- color: rgb(var(--mdw-color__outline));
10
- }
11
-
12
- .outline:is([pressed],[focused]) {
13
- color: rgb(var(--mdw-ink));
14
-
15
- transition-delay: 0;
16
- transition-duration: 0;
17
- }
18
-
19
- .outline[disabled] {
20
- color: rgba(var(--mdw-color__on-surface), 0.12);
21
- }
22
-
23
- .outline::before {
24
- content: '';
25
-
26
- position: absolute;
27
- inset: 0;
28
-
29
- border-style: solid;
30
- border-width: 1px;
31
-
32
- border-radius: inherit;
33
- }
34
-
35
- @supports(-webkit-mask-box-image: none) {
36
- .outline::before {
37
- content: none;
38
- }
39
-
40
- .outline::after {
41
- content: '';
42
-
43
- position: absolute;
44
- inset: 0;
45
-
46
- -webkit-mask-box-image: var(--mdw-shape__mask-image__edges)
47
- 8 fill /
48
- auto
49
- stretch;
50
-
51
- background-color: currentColor;
52
- }
53
-
54
- .outline-section {
55
- position: absolute;
56
- inset: 0;
57
- }
58
-
59
- .outline-section::before,
60
- .outline-section::after {
61
- content: "";
62
-
63
- position: absolute;
64
-
65
- max-block-size: 50%;
66
- max-inline-size: 50%;
67
-
68
- -webkit-mask-repeat: no-repeat;
69
- -webkit-mask-size: contain;
70
-
71
- background-color: currentColor;
72
-
73
- transition-duration: 200ms;
74
- /* stylelint-disable-next-line liberty/use-logical-spec */
75
- transition-property: width, height;
76
- }
77
-
78
- .outline-left::before {
79
- /* stylelint-disable-next-line liberty/use-logical-spec */
80
- left: calc(-1px * var(--mdw-shape__convex));
81
- inset-block-start: calc(-1px * var(--mdw-shape__convex));
82
-
83
- block-size: calc(var(--mdw-shape__size__top-left-size));
84
- inline-size: calc(var(--mdw-shape__size__top-left-size));
85
- /* stylelint-disable-next-line liberty/use-logical-spec */
86
- padding-right: calc(2px * var(--mdw-shape__convex));
87
- padding-block-end: calc(2px * var(--mdw-shape__convex));
88
-
89
- -webkit-mask-image: var(--mdw-shape__mask-image__top-left);
90
- }
91
-
92
- .outline-left::after {
93
- /* stylelint-disable-next-line liberty/use-logical-spec */
94
- left: calc(-1px * var(--mdw-shape__convex));
95
- inset-block-end: calc(-1px * var(--mdw-shape__convex));
96
-
97
- block-size: var(--mdw-shape__size__bottom-left-size);
98
- inline-size: var(--mdw-shape__size__bottom-left-size);
99
- /* stylelint-disable-next-line liberty/use-logical-spec */
100
- padding-right: calc(2px * var(--mdw-shape__convex));
101
- padding-block-start: calc(2px * var(--mdw-shape__convex));
102
-
103
- -webkit-mask-image: var(--mdw-shape__mask-image__bottom-left);
104
- -webkit-mask-position-y: 100%;
105
- }
106
-
107
- .outline-right::before {
108
- /* stylelint-disable-next-line liberty/use-logical-spec */
109
- right: calc(-1px * var(--mdw-shape__convex));
110
- inset-block-start: calc(-1px * var(--mdw-shape__convex));
111
-
112
- block-size: var(--mdw-shape__size__top-right-size);
113
- inline-size: var(--mdw-shape__size__top-right-size);
114
- /* stylelint-disable-next-line liberty/use-logical-spec */
115
- padding-left: calc(2px * var(--mdw-shape__convex));
116
- padding-block-end: calc(2px * var(--mdw-shape__convex));
117
-
118
- -webkit-mask-image: var(--mdw-shape__mask-image__top-right);
119
- -webkit-mask-position-x: 100%;
120
- }
121
-
122
- .outline-right::after {
123
- /* stylelint-disable-next-line liberty/use-logical-spec */
124
- right: calc(-1px * var(--mdw-shape__convex));
125
- inset-block-end: calc(-1px * var(--mdw-shape__convex));
126
-
127
- block-size: var(--mdw-shape__size__bottom-right-size);
128
- inline-size: var(--mdw-shape__size__bottom-right-size);
129
- /* stylelint-disable-next-line liberty/use-logical-spec */
130
- padding-left: calc(2px * var(--mdw-shape__convex));
131
- padding-block-start: calc(2px * var(--mdw-shape__convex));
132
-
133
- -webkit-mask-image: var(--mdw-shape__mask-image__bottom-right);
134
- -webkit-mask-position-x: 100%;
135
- -webkit-mask-position-y: 100%;
136
- }
137
-
138
- }