@operato/context 2.0.0-alpha.8 → 2.0.0-alpha.80

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 (62) hide show
  1. package/CHANGELOG.md +385 -0
  2. package/demo/index.html +13 -2
  3. package/dist/src/layouts/ox-context-page-toolbar.d.ts +9 -4
  4. package/dist/src/layouts/ox-context-page-toolbar.js +30 -10
  5. package/dist/src/layouts/ox-context-page-toolbar.js.map +1 -1
  6. package/dist/src/layouts/ox-context-toolbar.d.ts +2 -2
  7. package/dist/src/layouts/ox-context-toolbar.js +104 -70
  8. package/dist/src/layouts/ox-context-toolbar.js.map +1 -1
  9. package/dist/src/styles/ox-context-toolbar-overlay-style.js +2 -2
  10. package/dist/src/styles/ox-context-toolbar-overlay-style.js.map +1 -1
  11. package/dist/src/tools/ox-page-action-context-bar.d.ts +12 -5
  12. package/dist/src/tools/ox-page-action-context-bar.js +83 -44
  13. package/dist/src/tools/ox-page-action-context-bar.js.map +1 -1
  14. package/dist/src/tools/ox-page-action-overlay-template.d.ts +2 -2
  15. package/dist/src/tools/ox-page-action-overlay-template.js +28 -22
  16. package/dist/src/tools/ox-page-action-overlay-template.js.map +1 -1
  17. package/dist/src/tools/ox-page-title-bar.d.ts +2 -2
  18. package/dist/src/tools/ox-page-title-bar.js +6 -8
  19. package/dist/src/tools/ox-page-title-bar.js.map +1 -1
  20. package/dist/src/tools/ox-title-bar.d.ts +2 -2
  21. package/dist/src/tools/ox-title-bar.js +6 -8
  22. package/dist/src/tools/ox-title-bar.js.map +1 -1
  23. package/dist/stories/ox-context-page-toolbar-select-buttons.stories.d.ts +25 -0
  24. package/dist/stories/ox-context-page-toolbar-select-buttons.stories.js +127 -0
  25. package/dist/stories/ox-context-page-toolbar-select-buttons.stories.js.map +1 -0
  26. package/dist/stories/ox-context-page-toolbar-select.stories.d.ts +24 -0
  27. package/dist/stories/ox-context-page-toolbar-select.stories.js +85 -0
  28. package/dist/stories/ox-context-page-toolbar-select.stories.js.map +1 -0
  29. package/dist/stories/ox-context-page-toolbar.stories.d.ts +24 -0
  30. package/dist/stories/ox-context-page-toolbar.stories.js +90 -0
  31. package/dist/stories/ox-context-page-toolbar.stories.js.map +1 -0
  32. package/dist/stories/ox-context-toolbar-complex.stories.d.ts +19 -0
  33. package/dist/stories/ox-context-toolbar-complex.stories.js +147 -0
  34. package/dist/stories/ox-context-toolbar-complex.stories.js.map +1 -0
  35. package/dist/stories/ox-context-toolbar-empty.stories.d.ts +19 -0
  36. package/dist/stories/ox-context-toolbar-empty.stories.js +49 -0
  37. package/dist/stories/ox-context-toolbar-empty.stories.js.map +1 -0
  38. package/dist/stories/ox-context-toolbar-overflow.stories.d.ts +19 -0
  39. package/dist/stories/ox-context-toolbar-overflow.stories.js +128 -0
  40. package/dist/stories/ox-context-toolbar-overflow.stories.js.map +1 -0
  41. package/dist/stories/ox-context-toolbar.stories.d.ts +19 -0
  42. package/dist/stories/ox-context-toolbar.stories.js +83 -0
  43. package/dist/stories/ox-context-toolbar.stories.js.map +1 -0
  44. package/dist/tsconfig.tsbuildinfo +1 -1
  45. package/package.json +20 -20
  46. package/src/layouts/ox-context-page-toolbar.ts +33 -10
  47. package/src/layouts/ox-context-toolbar.ts +104 -70
  48. package/src/styles/ox-context-toolbar-overlay-style.ts +2 -2
  49. package/src/tools/ox-page-action-context-bar.ts +111 -63
  50. package/src/tools/ox-page-action-overlay-template.ts +48 -42
  51. package/src/tools/ox-page-title-bar.ts +6 -8
  52. package/src/tools/ox-title-bar.ts +6 -8
  53. package/stories/ox-context-page-toolbar-select-buttons.stories.ts +141 -0
  54. package/stories/ox-context-page-toolbar-select.stories.ts +99 -0
  55. package/stories/ox-context-page-toolbar.stories.ts +104 -0
  56. package/stories/ox-context-toolbar-complex.stories.ts +159 -0
  57. package/stories/ox-context-toolbar-empty.stories.ts +62 -0
  58. package/stories/ox-context-toolbar-overflow.stories.ts +140 -0
  59. package/stories/ox-context-toolbar.stories.ts +95 -0
  60. package/themes/app-theme.css +162 -0
  61. package/themes/context-theme.css +74 -0
  62. package/themes/material-theme.css +38 -0
package/CHANGELOG.md CHANGED
@@ -3,6 +3,391 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [2.0.0-alpha.80](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.79...v2.0.0-alpha.80) (2024-04-15)
7
+
8
+
9
+ ### :bug: Bug Fix
10
+
11
+ * context btn style & app theme ([80d9f5a](https://github.com/hatiolab/operato/commit/80d9f5acc9a363e5fee22aa8bc618a6234d55745))
12
+ * material theme ([7f9acfb](https://github.com/hatiolab/operato/commit/7f9acfbd97e933812bee45eaf4ab4bf90dc2e5dc))
13
+ * stories for styling ([f81021d](https://github.com/hatiolab/operato/commit/f81021d6ba12aa100bf29a0ea311cb46a6e99e45))
14
+
15
+
16
+
17
+ ## [2.0.0-alpha.77](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.76...v2.0.0-alpha.77) (2024-04-14)
18
+
19
+ **Note:** Version bump only for package @operato/context
20
+
21
+
22
+
23
+
24
+
25
+ ## [2.0.0-alpha.71](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.70...v2.0.0-alpha.71) (2024-04-13)
26
+
27
+ **Note:** Version bump only for package @operato/context
28
+
29
+
30
+
31
+
32
+
33
+ ## [2.0.0-alpha.69](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.68...v2.0.0-alpha.69) (2024-04-13)
34
+
35
+
36
+ ### :bug: Bug Fix
37
+
38
+ * mwc=>md for context ([972f5fd](https://github.com/hatiolab/operato/commit/972f5fd8da02820b6d6238cf1dd099591f97d8df))
39
+
40
+
41
+
42
+ ## [2.0.0-alpha.68](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.67...v2.0.0-alpha.68) (2024-04-13)
43
+
44
+
45
+ ### :bug: Bug Fix
46
+
47
+ * mwc=>md for context ([2bc13f2](https://github.com/hatiolab/operato/commit/2bc13f285f257782f73e5d7b5d1ddd197df85393))
48
+
49
+
50
+
51
+ ## [2.0.0-alpha.67](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.66...v2.0.0-alpha.67) (2024-04-13)
52
+
53
+
54
+ ### :bug: Bug Fix
55
+
56
+ * mwc=>md for context ([eacd9a5](https://github.com/hatiolab/operato/commit/eacd9a5b698969156f430f3d26233fdf7edccdf3))
57
+
58
+
59
+
60
+ ## [2.0.0-alpha.66](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.65...v2.0.0-alpha.66) (2024-04-13)
61
+
62
+
63
+ ### :bug: Bug Fix
64
+
65
+ * mwc=>md for context ([3d4217a](https://github.com/hatiolab/operato/commit/3d4217ae178ce568823697af2bdfbb244fda93c3))
66
+
67
+
68
+
69
+ ## [2.0.0-alpha.65](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.64...v2.0.0-alpha.65) (2024-04-13)
70
+
71
+
72
+ ### :bug: Bug Fix
73
+
74
+ * mwc=>md for context ([2b1a13b](https://github.com/hatiolab/operato/commit/2b1a13b9a214836ac7135717afd2dda536f1f487))
75
+
76
+
77
+
78
+ ## [2.0.0-alpha.64](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.63...v2.0.0-alpha.64) (2024-04-13)
79
+
80
+
81
+ ### :bug: Bug Fix
82
+
83
+ * context button style ([8b169de](https://github.com/hatiolab/operato/commit/8b169de8c18919c36e9e8a69059046046fb5293a))
84
+ * icon size ([b2e93e0](https://github.com/hatiolab/operato/commit/b2e93e04200145b2547edd11208ed6c895c156bc))
85
+ * mwc=>md for context ([269d5fe](https://github.com/hatiolab/operato/commit/269d5fedca38096ce41850afe88a17ed1fd656dd))
86
+
87
+
88
+
89
+ ## [2.0.0-alpha.63](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.62...v2.0.0-alpha.63) (2024-04-12)
90
+
91
+ **Note:** Version bump only for package @operato/context
92
+
93
+
94
+
95
+
96
+
97
+ ## [2.0.0-alpha.62](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.61...v2.0.0-alpha.62) (2024-04-12)
98
+
99
+
100
+ ### :bug: Bug Fix
101
+
102
+ * mwc=>md for context ([2a469f4](https://github.com/hatiolab/operato/commit/2a469f429544bd0cf9947a2efc381efafe8b0336))
103
+
104
+
105
+
106
+ ## [2.0.0-alpha.61](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.60...v2.0.0-alpha.61) (2024-04-11)
107
+
108
+ **Note:** Version bump only for package @operato/context
109
+
110
+
111
+
112
+
113
+
114
+ ## [2.0.0-alpha.60](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.59...v2.0.0-alpha.60) (2024-04-11)
115
+
116
+ **Note:** Version bump only for package @operato/context
117
+
118
+
119
+
120
+
121
+
122
+ ## [2.0.0-alpha.59](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.58...v2.0.0-alpha.59) (2024-04-11)
123
+
124
+ **Note:** Version bump only for package @operato/context
125
+
126
+
127
+
128
+
129
+
130
+ ## [2.0.0-alpha.57](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.56...v2.0.0-alpha.57) (2024-04-07)
131
+
132
+ **Note:** Version bump only for package @operato/context
133
+
134
+
135
+
136
+
137
+
138
+
139
+
140
+ **Note:** Version bump only for package @operato/context
141
+
142
+
143
+
144
+
145
+
146
+ ## [2.0.0-alpha.54](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.53...v2.0.0-alpha.54) (2024-04-01)
147
+
148
+ **Note:** Version bump only for package @operato/context
149
+
150
+
151
+
152
+
153
+
154
+ ## [2.0.0-alpha.53](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.52...v2.0.0-alpha.53) (2024-04-01)
155
+
156
+
157
+ ### :bug: Bug Fix
158
+
159
+ * storybook for ox-context-page-toolbar ([fa5b32d](https://github.com/hatiolab/operato/commit/fa5b32dfffd36db262e51c2706a5fbd719eed8ba))
160
+
161
+
162
+
163
+ ## [2.0.0-alpha.52](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.51...v2.0.0-alpha.52) (2024-03-29)
164
+
165
+ **Note:** Version bump only for package @operato/context
166
+
167
+
168
+
169
+
170
+
171
+ ## [2.0.0-alpha.51](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.50...v2.0.0-alpha.51) (2024-03-29)
172
+
173
+
174
+ ### :bug: Bug Fix
175
+
176
+ * upgrade lit ([e661c33](https://github.com/hatiolab/operato/commit/e661c333d2bb97f784b5ac2c0e365714ee5e80ff))
177
+
178
+
179
+
180
+ ## [2.0.0-alpha.49](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.48...v2.0.0-alpha.49) (2024-03-28)
181
+
182
+ **Note:** Version bump only for package @operato/context
183
+
184
+
185
+
186
+
187
+
188
+ ## [2.0.0-alpha.48](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.47...v2.0.0-alpha.48) (2024-03-28)
189
+
190
+
191
+ ### :bug: Bug Fix
192
+
193
+ * context module stories ([052ac6a](https://github.com/hatiolab/operato/commit/052ac6adc0c7cae6ddaff2babc3b344302e2aca8))
194
+
195
+
196
+
197
+ ## [2.0.0-alpha.47](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.46...v2.0.0-alpha.47) (2024-03-27)
198
+
199
+
200
+ ### :bug: Bug Fix
201
+
202
+ * storybook 실행 환경 ([6a2940f](https://github.com/hatiolab/operato/commit/6a2940fb89dc26566acdce7cf1781a71cbad61c5))
203
+
204
+
205
+
206
+ ## [2.0.0-alpha.46](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.45...v2.0.0-alpha.46) (2024-03-26)
207
+
208
+ **Note:** Version bump only for package @operato/context
209
+
210
+
211
+
212
+
213
+
214
+ ## [2.0.0-alpha.44](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.43...v2.0.0-alpha.44) (2024-03-24)
215
+
216
+ **Note:** Version bump only for package @operato/context
217
+
218
+
219
+
220
+
221
+
222
+ ## [2.0.0-alpha.43](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.42...v2.0.0-alpha.43) (2024-03-24)
223
+
224
+ **Note:** Version bump only for package @operato/context
225
+
226
+
227
+
228
+
229
+
230
+ ## [2.0.0-alpha.37](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.36...v2.0.0-alpha.37) (2024-03-18)
231
+
232
+ **Note:** Version bump only for package @operato/context
233
+
234
+
235
+
236
+
237
+
238
+ ## [2.0.0-alpha.35](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.34...v2.0.0-alpha.35) (2024-03-13)
239
+
240
+ **Note:** Version bump only for package @operato/context
241
+
242
+
243
+
244
+
245
+
246
+ ## [2.0.0-alpha.34](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.33...v2.0.0-alpha.34) (2024-03-12)
247
+
248
+ **Note:** Version bump only for package @operato/context
249
+
250
+
251
+
252
+
253
+
254
+ ## [2.0.0-alpha.32](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.31...v2.0.0-alpha.32) (2024-03-12)
255
+
256
+ **Note:** Version bump only for package @operato/context
257
+
258
+
259
+
260
+
261
+
262
+ ## [2.0.0-alpha.31](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.30...v2.0.0-alpha.31) (2024-03-03)
263
+
264
+ **Note:** Version bump only for package @operato/context
265
+
266
+
267
+
268
+
269
+
270
+ ## [2.0.0-alpha.30](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.29...v2.0.0-alpha.30) (2024-03-03)
271
+
272
+ **Note:** Version bump only for package @operato/context
273
+
274
+
275
+
276
+
277
+
278
+ ## [2.0.0-alpha.28](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.27...v2.0.0-alpha.28) (2024-02-20)
279
+
280
+
281
+ ### :bug: Bug Fix
282
+
283
+ * upgrade devDependencies for webcomponents ([1489b8b](https://github.com/hatiolab/operato/commit/1489b8b790d9bcee779a070a630697f25c01728f))
284
+
285
+
286
+
287
+ ## [2.0.0-alpha.27](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.26...v2.0.0-alpha.27) (2024-02-17)
288
+
289
+ **Note:** Version bump only for package @operato/context
290
+
291
+
292
+
293
+
294
+
295
+ ## [2.0.0-alpha.23](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.22...v2.0.0-alpha.23) (2024-02-10)
296
+
297
+ **Note:** Version bump only for package @operato/context
298
+
299
+
300
+
301
+
302
+
303
+ ## [2.0.0-alpha.22](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.21...v2.0.0-alpha.22) (2024-02-10)
304
+
305
+ **Note:** Version bump only for package @operato/context
306
+
307
+
308
+
309
+
310
+
311
+ ## [2.0.0-alpha.21](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.20...v2.0.0-alpha.21) (2024-02-09)
312
+
313
+ **Note:** Version bump only for package @operato/context
314
+
315
+
316
+
317
+
318
+
319
+ ## [2.0.0-alpha.20](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.19...v2.0.0-alpha.20) (2024-02-05)
320
+
321
+ **Note:** Version bump only for package @operato/context
322
+
323
+
324
+
325
+
326
+
327
+ ## [2.0.0-alpha.19](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.18...v2.0.0-alpha.19) (2024-02-05)
328
+
329
+ **Note:** Version bump only for package @operato/context
330
+
331
+
332
+
333
+
334
+
335
+ ## [2.0.0-alpha.17](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.16...v2.0.0-alpha.17) (2024-02-04)
336
+
337
+ **Note:** Version bump only for package @operato/context
338
+
339
+
340
+
341
+
342
+
343
+ ## [2.0.0-alpha.16](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.15...v2.0.0-alpha.16) (2024-02-03)
344
+
345
+ **Note:** Version bump only for package @operato/context
346
+
347
+
348
+
349
+
350
+
351
+ ## [2.0.0-alpha.13](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.12...v2.0.0-alpha.13) (2024-01-28)
352
+
353
+ **Note:** Version bump only for package @operato/context
354
+
355
+
356
+
357
+
358
+
359
+ ## [2.0.0-alpha.12](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.11...v2.0.0-alpha.12) (2024-01-24)
360
+
361
+ **Note:** Version bump only for package @operato/context
362
+
363
+
364
+
365
+
366
+
367
+ ## [2.0.0-alpha.11](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.10...v2.0.0-alpha.11) (2024-01-24)
368
+
369
+ **Note:** Version bump only for package @operato/context
370
+
371
+
372
+
373
+
374
+
375
+ ## [2.0.0-alpha.10](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.9...v2.0.0-alpha.10) (2024-01-22)
376
+
377
+ **Note:** Version bump only for package @operato/context
378
+
379
+
380
+
381
+
382
+
383
+ ## [2.0.0-alpha.9](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.8...v2.0.0-alpha.9) (2024-01-20)
384
+
385
+ **Note:** Version bump only for package @operato/context
386
+
387
+
388
+
389
+
390
+
6
391
  ## [2.0.0-alpha.8](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.7...v2.0.0-alpha.8) (2024-01-20)
7
392
 
8
393
  **Note:** Version bump only for package @operato/context
package/demo/index.html CHANGED
@@ -1,4 +1,4 @@
1
- <!DOCTYPE html>
1
+ <!doctype html>
2
2
  <html lang="en-GB">
3
3
  <head>
4
4
  <meta charset="utf-8" />
@@ -16,7 +16,18 @@
16
16
  }
17
17
  </style>
18
18
  <link href="https://fonts.googleapis.com/css?family=Roboto:300,400,500" rel="stylesheet" />
19
- <link href="https://fonts.googleapis.com/css?family=Material+Icons&display=block" rel="stylesheet" />
19
+ <link
20
+ href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL@20..48,100..700,0..1"
21
+ rel="stylesheet"
22
+ />
23
+ <link
24
+ href="https://fonts.googleapis.com/css2?family=Material+Symbols+Rounded:opsz,wght,FILL@20..48,100..700,0..1"
25
+ rel="stylesheet"
26
+ />
27
+ <link
28
+ href="https://fonts.googleapis.com/css2?family=Material+Symbols+Sharp:opsz,wght,FILL@20..48,100..700,0..1"
29
+ rel="stylesheet"
30
+ />
20
31
  </head>
21
32
  <body>
22
33
  <div id="demo"></div>
@@ -1,5 +1,6 @@
1
- import '@material/mwc-icon';
2
- import { LitElement } from 'lit';
1
+ import '@material/web/icon/icon.js';
2
+ import { LitElement, TemplateResult } from 'lit';
3
+ import { TOOL_POSITION } from '@operato/layout';
3
4
  declare const ContextPageToolbar_base: (new (...args: any[]) => {
4
5
  _storeUnsubscribe: import("redux").Unsubscribe;
5
6
  connectedCallback(): void;
@@ -10,8 +11,12 @@ declare const ContextPageToolbar_base: (new (...args: any[]) => {
10
11
  export declare class ContextPageToolbar extends ContextPageToolbar_base {
11
12
  static get styles(): import("lit").CSSResult[];
12
13
  context: any;
13
- private tools?;
14
- render(): import("lit").TemplateResult<1>;
14
+ tools?: {
15
+ position: TOOL_POSITION;
16
+ template: TemplateResult;
17
+ context?: string;
18
+ }[];
19
+ render(): TemplateResult<1>;
15
20
  stateChanged(state: any): void;
16
21
  }
17
22
  export {};
@@ -1,7 +1,7 @@
1
1
  import { __decorate } from "tslib";
2
- import '@material/mwc-icon';
2
+ import '@material/web/icon/icon.js';
3
3
  import { css, html, LitElement, nothing } from 'lit';
4
- import { customElement, property, state } from 'lit/decorators.js';
4
+ import { customElement, property } from 'lit/decorators.js';
5
5
  import { connect } from 'pwa-helpers/connect-mixin.js';
6
6
  import { TOOL_POSITION } from '@operato/layout';
7
7
  import { store } from '@operato/shell';
@@ -20,9 +20,7 @@ let ContextPageToolbar = class ContextPageToolbar extends connect(store)(LitElem
20
20
  --context-action-bar-button-margin: 0px;
21
21
  --context-action-bar-more-button-border-radius: 2px;
22
22
 
23
- --mdc-icon-size: 20px;
24
- --mdc-button-height: 20px;
25
- --mdc-button-horizontal-padding: 2px;
23
+ --md-icon-size: 20px;
26
24
  }
27
25
 
28
26
  :host > div {
@@ -30,17 +28,36 @@ let ContextPageToolbar = class ContextPageToolbar extends connect(store)(LitElem
30
28
  flex-direction: row;
31
29
 
32
30
  align-items: center;
31
+ gap: var(--padding-narrow);
33
32
  }
34
33
 
35
34
  * {
36
35
  cursor: pointer;
37
36
  }
38
37
 
39
- mwc-icon {
40
- background-color: var(--theme-white-color);
38
+ md-icon {
39
+ background-color: var(--button-background-color, #fafbfc);
41
40
  border: 1px solid rgba(var(--primary-color-rgb), 0.5);
42
- padding: 1px 2px;
41
+ border-radius: var(--button-border-radius);
42
+ padding: var(--iconbtn-padding, 4px);
43
+
43
44
  color: var(--primary-color);
45
+
46
+ &:hover {
47
+ background-color: var(--primary-color);
48
+
49
+ color: var(--theme-white-color);
50
+ }
51
+ }
52
+
53
+ @media screen and (max-width: 460px) {
54
+ :host > div {
55
+ gap: 0;
56
+ }
57
+
58
+ md-icon {
59
+ border-radius: 0;
60
+ }
44
61
  }
45
62
  `
46
63
  ];
@@ -74,14 +91,17 @@ let ContextPageToolbar = class ContextPageToolbar extends connect(store)(LitElem
74
91
  `;
75
92
  }
76
93
  stateChanged(state) {
77
- this.tools = state.context.tools;
94
+ var _a;
95
+ if (state.context) {
96
+ this.tools = (_a = state.context) === null || _a === void 0 ? void 0 : _a.tools;
97
+ }
78
98
  }
79
99
  };
80
100
  __decorate([
81
101
  property({ type: Object })
82
102
  ], ContextPageToolbar.prototype, "context", void 0);
83
103
  __decorate([
84
- state()
104
+ property({ type: Array })
85
105
  ], ContextPageToolbar.prototype, "tools", void 0);
86
106
  ContextPageToolbar = __decorate([
87
107
  customElement('ox-context-page-toolbar')
@@ -1 +1 @@
1
- {"version":3,"file":"ox-context-page-toolbar.js","sourceRoot":"","sources":["../../../src/layouts/ox-context-page-toolbar.ts"],"names":[],"mappings":";AAAA,OAAO,oBAAoB,CAAA;AAE3B,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,KAAK,CAAA;AACpD,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAS,KAAK,EAAE,MAAM,mBAAmB,CAAA;AACzE,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAA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ACH,CAAC;IAED,YAAY,CAAC,KAAU;QACrB,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,KAAK,CAAA;IAClC,CAAC;CACF,CAAA;AArC6B;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;mDAAa;AACvB;IAAhB,KAAK,EAAE;iDAAsB;AA1CnB,kBAAkB;IAD9B,aAAa,CAAC,yBAAyB,CAAC;GAC5B,kBAAkB,CA8E9B","sourcesContent":["import '@material/mwc-icon'\n\nimport { css, html, LitElement, nothing } from 'lit'\nimport { customElement, property, query, state } from 'lit/decorators.js'\nimport { connect } from 'pwa-helpers/connect-mixin.js'\n\nimport { TOOL_POSITION } from '@operato/layout'\nimport { store } from '@operato/shell'\n\n@customElement('ox-context-page-toolbar')\nexport class ContextPageToolbar extends connect(store)(LitElement) {\n static get styles() {\n return [\n css`\n :host {\n display: flex;\n flex-direction: row-reverse;\n position: relative;\n\n justify-content: end;\n align-items: center;\n\n --context-action-bar-button-margin: 0px;\n --context-action-bar-more-button-border-radius: 2px;\n\n --mdc-icon-size: 20px;\n --mdc-button-height: 20px;\n --mdc-button-horizontal-padding: 2px;\n }\n\n :host > div {\n display: flex;\n flex-direction: row;\n\n align-items: center;\n }\n\n * {\n cursor: pointer;\n }\n\n mwc-icon {\n background-color: var(--theme-white-color);\n border: 1px solid rgba(var(--primary-color-rgb), 0.5);\n padding: 1px 2px;\n color: var(--primary-color);\n }\n `\n ]\n }\n\n @property({ type: Object }) context: any\n @state() private tools?: any[]\n\n render() {\n let contextKeys = Object.keys(this.context).filter(key => !!this.context[key])\n let tools = (this.tools || []).filter(tool => {\n if (!tool.context || contextKeys.includes(tool.context)) {\n return tool\n }\n })\n\n let frontEndTools = tools.filter(tool => tool.position == TOOL_POSITION.FRONT_END)\n let frontTools = tools.filter(tool => tool.position == TOOL_POSITION.FRONT)\n let centerTools = tools.filter(tool => tool.position == TOOL_POSITION.CENTER)\n let rearTools = tools.filter(tool => tool.position == TOOL_POSITION.REAR)\n let rearEndTools = tools.filter(tool => tool.position == TOOL_POSITION.REAR_END)\n\n return html`\n ${frontEndTools.length > 0\n ? html`<div id=\"front-end\">${frontEndTools.map(tool => html` ${tool.template} `)}</div>`\n : nothing}\n ${frontTools.length > 0\n ? html`<div id=\"front\">${frontTools.map(tool => html` ${tool.template} `)}</div>`\n : nothing}\n ${centerTools.length > 0\n ? html`<div id=\"center\">${centerTools.map(tool => html` ${tool.template} `)}</div>`\n : nothing}\n ${rearTools.length > 0 ? html`<div id=\"rear\">${rearTools.map(tool => html` ${tool.template} `)}</div>` : nothing}\n ${rearEndTools.length > 0\n ? html`<div id=\"rear-end\">${rearEndTools.map(tool => html` ${tool.template} `)}</div>`\n : nothing}\n `\n }\n\n stateChanged(state: any) {\n this.tools = state.context.tools\n }\n}\n"]}
1
+ {"version":3,"file":"ox-context-page-toolbar.js","sourceRoot":"","sources":["../../../src/layouts/ox-context-page-toolbar.ts"],"names":[],"mappings":";AAAA,OAAO,4BAA4B,CAAA;AAEnC,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAkB,OAAO,EAAE,MAAM,KAAK,CAAA;AACpE,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAgB,MAAM,mBAAmB,CAAA;AACzE,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAA;AAEtD,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAC/C,OAAO,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAA;AAG/B,IAAM,kBAAkB,GAAxB,MAAM,kBAAmB,SAAQ,OAAO,CAAC,KAAK,CAAC,CAAC,UAAU,CAAC;IAChE,MAAM,KAAK,MAAM;QACf,OAAO;YACL,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAmDF;SACF,CAAA;IACH,CAAC;IASD,MAAM;QACJ,IAAI,WAAW,GAAG,MAAM,CAAC,IAAI,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AC;GAC5B,kBAAkB,CAqG9B","sourcesContent":["import '@material/web/icon/icon.js'\n\nimport { css, html, LitElement, TemplateResult, nothing } from 'lit'\nimport { customElement, property, query, state } from 'lit/decorators.js'\nimport { connect } from 'pwa-helpers/connect-mixin.js'\n\nimport { TOOL_POSITION } from '@operato/layout'\nimport { store } from '@operato/shell'\n\n@customElement('ox-context-page-toolbar')\nexport class ContextPageToolbar extends connect(store)(LitElement) {\n static get styles() {\n return [\n css`\n :host {\n display: flex;\n flex-direction: row-reverse;\n position: relative;\n\n justify-content: end;\n align-items: center;\n\n --context-action-bar-button-margin: 0px;\n --context-action-bar-more-button-border-radius: 2px;\n\n --md-icon-size: 20px;\n }\n\n :host > div {\n display: flex;\n flex-direction: row;\n\n align-items: center;\n gap: var(--padding-narrow);\n }\n\n * {\n cursor: pointer;\n }\n\n md-icon {\n background-color: var(--button-background-color, #fafbfc);\n border: 1px solid rgba(var(--primary-color-rgb), 0.5);\n border-radius: var(--button-border-radius);\n padding: var(--iconbtn-padding, 4px);\n\n color: var(--primary-color);\n\n &:hover {\n background-color: var(--primary-color);\n\n color: var(--theme-white-color);\n }\n }\n\n @media screen and (max-width: 460px) {\n :host > div {\n gap: 0;\n }\n\n md-icon {\n border-radius: 0;\n }\n }\n `\n ]\n }\n\n @property({ type: Object }) context: any\n @property({ type: Array }) tools?: {\n position: TOOL_POSITION\n template: TemplateResult\n context?: string\n }[]\n\n render() {\n let contextKeys = Object.keys(this.context).filter(key => !!this.context[key])\n let tools = (this.tools || []).filter(tool => {\n if (!tool.context || contextKeys.includes(tool.context)) {\n return tool\n }\n })\n\n let frontEndTools = tools.filter(tool => tool.position == TOOL_POSITION.FRONT_END)\n let frontTools = tools.filter(tool => tool.position == TOOL_POSITION.FRONT)\n let centerTools = tools.filter(tool => tool.position == TOOL_POSITION.CENTER)\n let rearTools = tools.filter(tool => tool.position == TOOL_POSITION.REAR)\n let rearEndTools = tools.filter(tool => tool.position == TOOL_POSITION.REAR_END)\n\n return html`\n ${frontEndTools.length > 0\n ? html`<div id=\"front-end\">${frontEndTools.map(tool => html` ${tool.template} `)}</div>`\n : nothing}\n ${frontTools.length > 0\n ? html`<div id=\"front\">${frontTools.map(tool => html` ${tool.template} `)}</div>`\n : nothing}\n ${centerTools.length > 0\n ? html`<div id=\"center\">${centerTools.map(tool => html` ${tool.template} `)}</div>`\n : nothing}\n ${rearTools.length > 0 ? html`<div id=\"rear\">${rearTools.map(tool => html` ${tool.template} `)}</div>` : nothing}\n ${rearEndTools.length > 0\n ? html`<div id=\"rear-end\">${rearEndTools.map(tool => html` ${tool.template} `)}</div>`\n : nothing}\n `\n }\n\n stateChanged(state: any) {\n if (state.context) {\n this.tools = state.context?.tools\n }\n }\n}\n"]}
@@ -1,4 +1,4 @@
1
- import '@material/mwc-icon';
1
+ import '@material/web/icon/icon.js';
2
2
  import { LitElement, nothing } from 'lit';
3
3
  declare const ContextToolbar_base: (new (...args: any[]) => {
4
4
  _storeUnsubscribe: import("redux").Unsubscribe;
@@ -11,7 +11,7 @@ export declare class ContextToolbar extends ContextToolbar_base {
11
11
  static get styles(): import("lit").CSSResult[];
12
12
  private context;
13
13
  private tools?;
14
- render(): import("lit").TemplateResult<1> | typeof nothing;
14
+ render(): typeof nothing | import("lit-html").TemplateResult<1>;
15
15
  stateChanged(state: any): void;
16
16
  }
17
17
  export {};