@materializecss/materialize 2.0.3-alpha → 2.0.3-beta

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.
@@ -1 +1 @@
1
- {"version":3,"file":"global.d.ts","sourceRoot":"","sources":["../../src/global.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,oBAAoB,EAAE,MAAM,WAAW,CAAC;AAEjD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,KAAK,EAAE,YAAY,EAAE,MAAM,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QAAQ,EAAE,OAAO,QAAQ,CAAY;IAC5C,MAAM,CAAC,MAAM,EAAE,OAAO,MAAM,CAAU;IACtC,MAAM,CAAC,UAAU,EAAE,OAAO,UAAU,CAAc;IAClD,uBAAuB;IACvB,MAAM,CAAC,KAAK,EAAE,CAAC,GAAG,EAAE,OAAO,CAAC,YAAY,CAAC,KAAK,KAAK,CAA4B;IAC/E,MAAM,CAAC,OAAO,EAAE,OAAO,OAAO,CAAW;IACzC,MAAM,CAAC,OAAO,EAAE,OAAO,OAAO,CAAW;IACzC,MAAM,CAAC,SAAS,EAAE,OAAO,SAAS,CAAa;IAC/C,MAAM,CAAC,SAAS,EAAE,OAAO,SAAS,CAAa;IAC/C,MAAM,CAAC,KAAK,EAAE,OAAO,KAAK,CAAS;IACnC,MAAM,CAAC,KAAK,EAAE,OAAO,KAAK,CAAS;IACnC,MAAM,CAAC,KAAK,EAAE,OAAO,KAAK,CAAS;IAcnC;;;OAGG;IACH,MAAM,CAAC,QAAQ,CAAC,OAAO,GAAE,WAA2B;CAwCrD"}
@@ -1,4 +1,5 @@
1
1
  import { Component, BaseOptions, InitElements, MElement } from "./component";
2
+ export type TooltipPosition = 'top' | 'right' | 'bottom' | 'left';
2
3
  export interface TooltipOptions extends BaseOptions {
3
4
  /**
4
5
  * Delay time before tooltip disappears.
@@ -10,6 +11,11 @@ export interface TooltipOptions extends BaseOptions {
10
11
  * @default 0
11
12
  */
12
13
  enterDelay: number;
14
+ /**
15
+ * Element Id for the tooltip.
16
+ * @default ""
17
+ */
18
+ tooltipId?: string;
13
19
  /**
14
20
  * Text string for the tooltip.
15
21
  * @default ""
@@ -40,7 +46,7 @@ export interface TooltipOptions extends BaseOptions {
40
46
  * Set the direction of the tooltip.
41
47
  * @default 'bottom'
42
48
  */
43
- position: 'top' | 'right' | 'bottom' | 'left';
49
+ position: TooltipPosition;
44
50
  /**
45
51
  * Amount in px that the tooltip moves during its transition.
46
52
  * @default 10
@@ -107,6 +113,6 @@ export declare class Tooltip extends Component<TooltipOptions> {
107
113
  _handleMouseLeave: () => void;
108
114
  _handleFocus: () => void;
109
115
  _handleBlur: () => void;
110
- _getAttributeOptions(): {};
116
+ _getAttributeOptions(): Partial<TooltipOptions>;
111
117
  }
112
118
  //# sourceMappingURL=tooltip.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tooltip.d.ts","sourceRoot":"","sources":["../../src/tooltip.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAE7E,MAAM,WAAW,cAAe,SAAQ,WAAW;IACjD;;;OAGG;IACH,SAAS,EAAE,MAAM,CAAC;IAClB;;;OAGG;IACH,UAAU,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,IAAI,EAAE,MAAM,CAAC;IACb;;;;OAIG;IACH,MAAM,EAAE,MAAM,CAAC;IACf;;;OAGG;IACH,UAAU,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,OAAO,EAAE,MAAM,CAAC;IAChB;;;OAGG;IACH,WAAW,EAAE,MAAM,CAAC;IACpB;;;OAGG;IACH,QAAQ,EAAE,KAAK,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,CAAC;IAC9C;;;OAGG;IACH,kBAAkB,EAAE,MAAM,CAAC;CAC5B;AAcD,qBAAa,OAAQ,SAAQ,SAAS,CAAC,cAAc,CAAC;IACpD;;OAEG;IACH,MAAM,EAAE,OAAO,CAAC;IAChB;;OAEG;IACH,SAAS,EAAE,OAAO,CAAC;IACnB;;OAEG;IACH,SAAS,EAAE,OAAO,CAAC;IACnB,SAAS,EAAE,WAAW,CAAC;IACvB,OAAO,CAAC,iBAAiB,CAAmC;IAC5D,OAAO,CAAC,kBAAkB,CAAmC;IAC7D,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;gBAEN,EAAE,EAAE,WAAW,EAAE,OAAO,EAAE,OAAO,CAAC,cAAc,CA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hD,qBAAqB;IAIrB,mBAAmB;IAOnB,oBAAoB;IAOpB;;OAEG;IACH,IAAI,aAAc,OAAO,UAQxB;IAED;;OAEG;IACH,KAAK,aAMJ;IAED,oBAAoB;IAQpB,qBAAqB,CAAC,QAAQ,KAAA;IAQ9B,gBAAgB;IA0ChB,uBAAuB,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM;;;;IA+B3E,UAAU;IAcV,WAAW;IAYX,iBAAiB,aAIhB;IAED,iBAAiB,aAIhB;IAED,YAAY,aAKX;IAED,WAAW,aAGV;IAED,oBAAoB,IAAI,OAAO,CAAC,cAAc,CAAC;CAiBhD"}
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "Builds Materialize distribution packages",
4
4
  "author": "Alvin Wang, Alan Chang",
5
5
  "homepage": "https://materializecss.github.io/materialize/",
6
- "version": "2.0.3-alpha",
6
+ "version": "2.0.3-beta",
7
7
  "main": "dist/js/materialize.js",
8
8
  "module": "src/index.ts",
9
9
  "style": "dist/css/materialize.css",
@@ -23,7 +23,6 @@
23
23
  "release": "grunt release",
24
24
  "watch": "webpack --watch",
25
25
  "precommit": "lint-staged",
26
- "docs": "grunt docs",
27
26
  "commit": "npx cz",
28
27
  "_postinstall": "husky install",
29
28
  "prepack": "pinst --disable",
@@ -51,9 +50,7 @@
51
50
  "grunt-concurrent": "^3.0.0",
52
51
  "grunt-contrib-compress": "^1.4.1",
53
52
  "grunt-contrib-connect": "^3.0.0",
54
- "grunt-contrib-copy": "^1.0.0",
55
53
  "grunt-contrib-jasmine": "^3.0.0",
56
- "grunt-contrib-pug": "^3.0.0",
57
54
  "grunt-contrib-watch": "^1.0.0",
58
55
  "grunt-postcss": "^0.9.0",
59
56
  "grunt-remove-logging": "^0.2.0",
@@ -1,18 +1,58 @@
1
- // shared styles
2
- .btn,
3
- .btn-flat {
4
- font-weight: 500;
5
- border: $button-border;
6
- border-radius: $button-radius;
7
- display: inline-block;
1
+ .btn, .btn-floating, .btn-large, .btn-small, .btn-flat {
2
+ --font-size-icon: 16px;
3
+ --padding: 24px;
4
+ --padding-icon: 16px;
5
+ --gap-icon: 8px;
6
+
8
7
  height: $button-height;
9
- line-height: $button-height;
10
- padding: $button-padding;
11
- vertical-align: middle;
12
- user-select: none;
8
+
9
+ // line-height: $button-height;
10
+ border: $button-border;
11
+ border-radius: $button-radius;
12
+
13
+ // padding: $button-padding;
14
+ padding-left: var(--padding);
15
+ padding-right: var(--padding);
16
+
17
+ color: $button-raised-color;
18
+ font-size: $button-font-size;
19
+ font-weight: 500;
20
+ text-decoration: none;
21
+
22
+ display: inline-flex;
23
+ align-items: center;
24
+
25
+ cursor: pointer;
13
26
  -webkit-tap-highlight-color: transparent; // Gets rid of tap active state
27
+ white-space: nowrap;
28
+ outline: 0;
29
+ user-select: none;
30
+
31
+ transition: background-color .2s ease-out;
14
32
  }
15
33
 
34
+ // Icon
35
+ .btn.icon-left, .btn.icon-right {
36
+ position: relative;
37
+ }
38
+ .btn.icon-left {
39
+ padding-left: calc(var(--padding-icon) + var(--font-size-icon) + var(--gap-icon));
40
+ }
41
+ .btn.icon-right {
42
+ padding-right: calc(var(--padding-icon) + var(--font-size-icon) + var(--gap-icon));
43
+ }
44
+ .btn.icon-left i, .btn.icon-right i {
45
+ position: absolute;
46
+ font-size: var(--font-size-icon);
47
+ }
48
+ .btn.icon-left i {
49
+ left: var(--padding-icon);
50
+ }
51
+ .btn.icon-right i {
52
+ right: var(--padding-icon);
53
+ }
54
+
55
+
16
56
  // Disabled shared style
17
57
  .btn.disabled,
18
58
  .btn-floating.disabled,
@@ -40,53 +80,103 @@
40
80
  }
41
81
  }
42
82
 
43
- // Shared icon styles
44
- .btn,
45
- .btn-floating,
46
- .btn-large,
47
- .btn-small,
48
- .btn-flat {
49
- font-size: $button-font-size;
50
- outline: 0;
51
- i {
52
- font-size: $button-icon-font-size;
53
- line-height: inherit;
83
+ //--- Filled Button
84
+ .btn.filled {
85
+ background-color: var(--md-sys-color-primary);
86
+ }
87
+ //--- Filled Tonal
88
+ .btn.tonal {
89
+ background-color: var(--md-sys-color-secondary-container);
90
+ color: var(--md-sys-color-on-secondary-container);
91
+ }
92
+ //--- Text-Button (Flat)
93
+ .btn.text, .btn-flat {
94
+ box-shadow: none;
95
+ background-color: transparent;
96
+ color: var(--md-sys-color-primary);
97
+ cursor: pointer;
98
+ transition: background-color .2s;
99
+ &:focus,
100
+ &:hover {
101
+ box-shadow: none;
102
+ background-color: $button-flat-hover-background-color;
103
+ }
104
+ &:focus {
105
+ background-color: $button-flat-focus-background-color;
106
+ }
107
+ &.disabled,
108
+ &.btn.text[disabled], &.btn-flat[disabled] {
109
+ background-color: transparent !important;
110
+ color: $button-flat-disabled-color !important;
111
+ cursor: default;
54
112
  }
55
113
  }
114
+ //--- Outlined-Button
115
+ .btn.outlined {
116
+ background-color: transparent;
117
+ color: $button-raised-background;
118
+ border: 1px solid $button-raised-background;
119
+ }
120
+ //--- Elevated
121
+ .btn.elevated {
122
+ @extend .tonal;
123
+ @extend .z-depth-1;
124
+ }
125
+
126
+
127
+ //======================== States (Hover, Focused, ...)
56
128
 
57
- // Raised Button
58
129
  .btn {
59
- text-decoration: none;
60
- color: $button-raised-color;
61
- background-color: $button-raised-background;
62
- text-align: center;
63
- letter-spacing: .5px;
64
- @extend .z-depth-1;
65
- transition: background-color .2s ease-out;
66
- cursor: pointer;
130
+ @extend .filled;
131
+
67
132
  &:hover {
68
133
  background-color: $button-raised-background-hover;
69
134
  @extend .z-depth-1-half;
70
135
  }
136
+
71
137
  &:focus {
72
138
  background-color: $button-raised-background-focus;
73
139
  @extend .z-depth-1-half;
74
- }
140
+ }
75
141
  }
76
142
 
143
+
144
+
145
+ //----------
146
+ // .btn-floating {
147
+ // border-radius: 16px;
148
+ // width: unset;
149
+ // display: grid;
150
+ // grid-auto-flow: column;
151
+ // align-items: center;
152
+ // padding: 16px !important;
153
+ // padding-right: 24px !important; /* only with icon */
154
+ // gap: 8px;
155
+ // }
156
+ // .btn-floating.btn-large {
157
+ // width: unset;
158
+ // }
159
+ // .btn-large {
160
+ // font-size: 14px;
161
+ // }
162
+ //-----
77
163
  // Floating button
78
164
  .btn-floating {
165
+
79
166
  &:hover {
80
167
  background-color: $button-floating-background-hover;
81
168
  @extend .z-depth-1-half;
82
169
  }
170
+
83
171
  &:focus {
84
172
  background-color: $button-floating-background-focus;
85
173
  @extend .z-depth-1-half;
86
174
  }
175
+
87
176
  &:before {
88
177
  border-radius: 0;
89
178
  }
179
+
90
180
  &.btn-large {
91
181
  &.halfway-fab {
92
182
  bottom: -$button-floating-large-size * 0.5;
@@ -94,9 +184,10 @@
94
184
  width: $button-floating-large-size;
95
185
  height: $button-floating-large-size;
96
186
  padding: 0;
97
- i {
98
- line-height: $button-floating-large-size;
99
- }
187
+ // font-size:
188
+ // i {
189
+ // // line-height: $button-floating-large-size;
190
+ // }
100
191
  }
101
192
 
102
193
  &.btn-small {
@@ -105,9 +196,9 @@
105
196
  }
106
197
  width: $button-floating-small-size;
107
198
  height: $button-floating-small-size;
108
- i {
109
- line-height: $button-floating-small-size;
110
- }
199
+ // i {
200
+ // line-height: $button-floating-small-size;
201
+ // }
111
202
  }
112
203
 
113
204
  &.halfway-fab {
@@ -119,36 +210,48 @@
119
210
  right: 24px;
120
211
  bottom: -$button-floating-size * 0.5;
121
212
  }
122
- display: inline-block;
213
+
214
+ // FIXES
215
+ // width: unset;
216
+ // padding: 16px !important;
217
+ // padding-right: 24px !important; /* only with icon */
218
+ // gap: 8px;
219
+
123
220
  color: $button-floating-color;
124
- position: relative;
125
- overflow: hidden;
126
- z-index: 1;
221
+
127
222
  width: $button-floating-size;
128
223
  height: $button-floating-size;
129
- line-height: $button-floating-size;
130
- padding: 0;
224
+ // line-height: $button-floating-size;
225
+
131
226
  background-color: $button-floating-background;
132
227
  border-radius: $button-floating-radius;
228
+ padding: 0;
229
+
230
+ display: grid;
231
+ grid-auto-flow: column;
232
+ align-items: center;
233
+
234
+ position: relative;
235
+ overflow: hidden;
236
+ z-index: 1;
133
237
  @extend .z-depth-1;
134
238
  transition: background-color .3s;
135
239
  cursor: pointer;
136
240
  vertical-align: middle;
241
+
137
242
  i {
243
+ color: $button-floating-color;
244
+ font-size: $button-large-icon-font-size;
245
+ // line-height: $button-floating-size;
138
246
  width: inherit;
139
247
  display: inline-block;
140
248
  text-align: center;
141
- color: $button-floating-color;
142
- font-size: $button-large-icon-font-size;
143
- line-height: $button-floating-size;
144
249
  }
145
250
  }
146
-
147
251
  // button fix
148
252
  button.btn-floating {
149
253
  border: $button-border;
150
254
  }
151
-
152
255
  // Fixed Action Button
153
256
  .fixed-action-btn {
154
257
  &.active {
@@ -274,37 +377,15 @@ button.btn-floating {
274
377
  }
275
378
  }
276
379
 
277
- // Flat button
278
- .btn-flat {
279
- box-shadow: none;
280
- background-color: transparent;
281
- color: $button-flat-color;
282
- cursor: pointer;
283
- transition: background-color .2s;
284
- &:focus,
285
- &:hover {
286
- box-shadow: none;
287
- background-color: $button-flat-hover-background-color;
288
- }
289
- &:focus {
290
- background-color: $button-flat-focus-background-color;
291
- }
292
- &.disabled,
293
- &.btn-flat[disabled] {
294
- background-color: transparent !important;
295
- color: $button-flat-disabled-color !important;
296
- cursor: default;
297
- }
298
- }
380
+ //--- Helper classes (for all)
299
381
 
300
382
  // Large button
301
383
  .btn-large {
302
384
  @extend .btn;
303
385
  height: $button-large-height;
304
- line-height: $button-large-height;
386
+ // line-height: $button-large-height;
305
387
  font-size: $button-large-font-size;
306
388
  padding: 0 28px;
307
-
308
389
  i {
309
390
  font-size: $button-large-icon-font-size;
310
391
  }
@@ -325,3 +406,7 @@ button.btn-floating {
325
406
  .btn-block {
326
407
  display: block;
327
408
  }
409
+
410
+ .btn.rounded {
411
+ border-radius: 99999px;
412
+ }
@@ -1,45 +1,87 @@
1
1
  .chip {
2
+ --font-size: 14px;
3
+ --font-size-icon: 18px;
4
+ --padding: 8px;
5
+
6
+ background-color: $chip-bg-color;
7
+
8
+ display: inline-flex;
9
+ white-space: nowrap;
10
+ gap: 8px;
11
+
12
+ margin: 0;
13
+ height: 32px;
14
+
15
+ padding-left: var(--padding);
16
+ padding-right: var(--padding);
17
+
18
+ font-size: var(--font-size);
19
+ font-weight: 500;
20
+ color: $chip-font-color;
21
+
22
+ border-radius: 8px;
23
+
24
+ align-items: center;
25
+ user-select: none;
26
+ vertical-align: top;
27
+
2
28
  &:focus {
3
29
  outline: none;
4
30
  background-color: $chip-selected-color;
5
31
  color: $chip-selected-font-color;
6
32
  }
33
+ }
7
34
 
8
- display: inline-block;
9
- height: 32px;
10
- font-size: 13px;
11
- font-weight: 500;
12
- color: $chip-font-color;
13
- line-height: 32px;
14
- padding: 0 12px;
15
- border-radius: 16px;
16
- background-color: $chip-bg-color;
17
- margin-bottom: $chip-margin;
18
- margin-right: $chip-margin;
35
+ .chip.outlined {
36
+ background-color: transparent;
37
+ border-color: var(--md-sys-color-outline);
38
+ border-width: 1px;
39
+ border-style: solid;
40
+ }
19
41
 
20
- > img {
21
- float: left;
22
- margin: 0 8px 0 -12px;
23
- height: 32px;
24
- width: 32px;
25
- border-radius: 50%;
26
- }
42
+ .chip > img {
43
+ margin: 0;
44
+ width: 24px;
45
+ height: 24px;
46
+ object-fit: cover;
47
+ border-radius: 12px;
48
+ }
27
49
 
28
- .close {
29
- cursor: pointer;
30
- float: right;
31
- font-size: 16px;
32
- line-height: 32px;
33
- padding-left: 8px;
34
- }
50
+ .chip > .material-icons {
51
+ font-size: var(--font-size-icon);
52
+ @extend .on-surface-variant-text;
53
+ }
54
+
55
+ .chip .close {
56
+ border-radius: 50%;
57
+ height: 24px;
58
+ width: 24px;
59
+ padding: 0;
60
+ display: grid;
61
+ justify-content: center;
62
+ align-content: center;
63
+ cursor: pointer;
64
+ }
65
+
66
+ .chip .close:hover {
67
+ background-color: #8888;
35
68
  }
36
69
 
70
+ //--------------------------
71
+
37
72
  .chips {
73
+ display: flex;
74
+ gap: 4px;
75
+ flex-wrap: wrap;
76
+
38
77
  border: none;
39
78
  border-bottom: 1px solid $chip-border-color;
40
79
  box-shadow: none;
41
80
  margin: $input-margin;
42
- min-height: 45px;
81
+
82
+ padding: 4px;
83
+ // min-height: 45px;
84
+
43
85
  outline: none;
44
86
  transition: all .3s;
45
87
 
@@ -58,13 +100,18 @@
58
100
  color: $input-color;
59
101
  display: inline-block;
60
102
  font-size: $input-font-size;
61
- height: $input-height;
62
- line-height: 32px;
103
+
104
+ // height: 32px;
105
+ // height: $input-height;
106
+ // line-height: 32px;
107
+ height: 32px;
108
+
63
109
  outline: 0;
64
110
  margin: 0;
65
111
  padding: 0;
66
112
  width: 120px;
67
113
 
114
+
68
115
  &:focus {
69
116
  border: 0;
70
117
  box-shadow: none;