@operato/popup 2.0.0-alpha.0 → 2.0.0-alpha.100

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 (53) hide show
  1. package/CHANGELOG.md +220 -0
  2. package/demo/index.html +25 -14
  3. package/demo/ox-popup-list.html +14 -3
  4. package/demo/ox-popup-menu.html +25 -14
  5. package/dist/src/ox-floating-overlay.d.ts +67 -2
  6. package/dist/src/ox-floating-overlay.js +35 -8
  7. package/dist/src/ox-floating-overlay.js.map +1 -1
  8. package/dist/src/ox-popup-list.d.ts +51 -2
  9. package/dist/src/ox-popup-list.js +47 -10
  10. package/dist/src/ox-popup-list.js.map +1 -1
  11. package/dist/src/ox-popup-menu.d.ts +16 -2
  12. package/dist/src/ox-popup-menu.js +15 -1
  13. package/dist/src/ox-popup-menu.js.map +1 -1
  14. package/dist/src/ox-popup-menuitem.d.ts +29 -1
  15. package/dist/src/ox-popup-menuitem.js +27 -2
  16. package/dist/src/ox-popup-menuitem.js.map +1 -1
  17. package/dist/src/ox-popup.d.ts +30 -9
  18. package/dist/src/ox-popup.js +42 -14
  19. package/dist/src/ox-popup.js.map +1 -1
  20. package/dist/src/ox-prompt.d.ts +80 -3
  21. package/dist/src/ox-prompt.js +94 -9
  22. package/dist/src/ox-prompt.js.map +1 -1
  23. package/dist/stories/open-popup.stories.js +27 -18
  24. package/dist/stories/open-popup.stories.js.map +1 -1
  25. package/dist/stories/ox-popup-list.stories.d.ts +1 -1
  26. package/dist/stories/ox-popup-list.stories.js +15 -3
  27. package/dist/stories/ox-popup-list.stories.js.map +1 -1
  28. package/dist/stories/ox-popup-menu.stories.d.ts +1 -1
  29. package/dist/stories/ox-popup-menu.stories.js +37 -25
  30. package/dist/stories/ox-popup-menu.stories.js.map +1 -1
  31. package/dist/stories/ox-prompt-icon.stories.d.ts +25 -0
  32. package/dist/stories/ox-prompt-icon.stories.js +59 -0
  33. package/dist/stories/ox-prompt-icon.stories.js.map +1 -0
  34. package/dist/stories/ox-prompt-normal.stories.js +26 -13
  35. package/dist/stories/ox-prompt-normal.stories.js.map +1 -1
  36. package/dist/stories/ox-prompt.stories.js +26 -13
  37. package/dist/stories/ox-prompt.stories.js.map +1 -1
  38. package/dist/tsconfig.tsbuildinfo +1 -1
  39. package/package.json +16 -16
  40. package/src/ox-floating-overlay.ts +84 -8
  41. package/src/ox-popup-list.ts +64 -10
  42. package/src/ox-popup-menu.ts +15 -1
  43. package/src/ox-popup-menuitem.ts +31 -2
  44. package/src/ox-popup.ts +46 -16
  45. package/src/ox-prompt.ts +126 -9
  46. package/stories/open-popup.stories.ts +28 -20
  47. package/stories/ox-popup-list.stories.ts +15 -3
  48. package/stories/ox-popup-menu.stories.ts +38 -27
  49. package/stories/ox-prompt-icon.stories.ts +76 -0
  50. package/stories/ox-prompt-normal.stories.ts +29 -17
  51. package/stories/ox-prompt.stories.ts +29 -17
  52. package/themes/input-theme.css +7 -7
  53. package/themes/material-theme.css +88 -0
package/CHANGELOG.md CHANGED
@@ -3,6 +3,226 @@
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.100](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.99...v2.0.0-alpha.100) (2024-04-21)
7
+
8
+ **Note:** Version bump only for package @operato/popup
9
+
10
+
11
+
12
+
13
+
14
+ ## [2.0.0-alpha.99](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.98...v2.0.0-alpha.99) (2024-04-21)
15
+
16
+ **Note:** Version bump only for package @operato/popup
17
+
18
+
19
+
20
+
21
+
22
+ ## [2.0.0-alpha.98](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.97...v2.0.0-alpha.98) (2024-04-21)
23
+
24
+ **Note:** Version bump only for package @operato/popup
25
+
26
+
27
+
28
+
29
+
30
+ ## [2.0.0-alpha.94](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.93...v2.0.0-alpha.94) (2024-04-20)
31
+
32
+
33
+ ### :bug: Bug Fix
34
+
35
+ * support 'checkbox' type in ox-filters-form-base ([1ffe0e5](https://github.com/hatiolab/operato/commit/1ffe0e5fc16480240c8c5accf57d247bb3299867))
36
+
37
+
38
+
39
+ ## [2.0.0-alpha.92](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.91...v2.0.0-alpha.92) (2024-04-19)
40
+
41
+ **Note:** Version bump only for package @operato/popup
42
+
43
+
44
+
45
+
46
+
47
+ ## [2.0.0-alpha.90](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.89...v2.0.0-alpha.90) (2024-04-18)
48
+
49
+ **Note:** Version bump only for package @operato/popup
50
+
51
+
52
+
53
+
54
+
55
+ ## [2.0.0-alpha.89](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.88...v2.0.0-alpha.89) (2024-04-18)
56
+
57
+ **Note:** Version bump only for package @operato/popup
58
+
59
+
60
+
61
+
62
+
63
+ ## [2.0.0-alpha.87](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.86...v2.0.0-alpha.87) (2024-04-17)
64
+
65
+ **Note:** Version bump only for package @operato/popup
66
+
67
+
68
+
69
+
70
+
71
+ ## [2.0.0-alpha.85](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.84...v2.0.0-alpha.85) (2024-04-16)
72
+
73
+
74
+ ### :bug: Bug Fix
75
+
76
+ * tweak filters-form style ([6fb293d](https://github.com/hatiolab/operato/commit/6fb293d7d34ea7b01b3011264f554158beb62621))
77
+
78
+
79
+
80
+ ## [2.0.0-alpha.82](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.81...v2.0.0-alpha.82) (2024-04-15)
81
+
82
+ **Note:** Version bump only for package @operato/popup
83
+
84
+
85
+
86
+
87
+
88
+ ## [2.0.0-alpha.81](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.80...v2.0.0-alpha.81) (2024-04-15)
89
+
90
+ **Note:** Version bump only for package @operato/popup
91
+
92
+
93
+
94
+
95
+
96
+ ## [2.0.0-alpha.80](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.79...v2.0.0-alpha.80) (2024-04-15)
97
+
98
+ **Note:** Version bump only for package @operato/popup
99
+
100
+
101
+
102
+
103
+
104
+ ## [2.0.0-alpha.68](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.67...v2.0.0-alpha.68) (2024-04-13)
105
+
106
+
107
+ ### :bug: Bug Fix
108
+
109
+ * mwc=>md for context ([2bc13f2](https://github.com/hatiolab/operato/commit/2bc13f285f257782f73e5d7b5d1ddd197df85393))
110
+
111
+
112
+
113
+ ## [2.0.0-alpha.62](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.61...v2.0.0-alpha.62) (2024-04-12)
114
+
115
+ **Note:** Version bump only for package @operato/popup
116
+
117
+
118
+
119
+
120
+
121
+ ## [2.0.0-alpha.57](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.56...v2.0.0-alpha.57) (2024-04-07)
122
+
123
+ **Note:** Version bump only for package @operato/popup
124
+
125
+
126
+
127
+
128
+
129
+
130
+
131
+ **Note:** Version bump only for package @operato/popup
132
+
133
+
134
+
135
+
136
+
137
+ ## [2.0.0-alpha.52](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.51...v2.0.0-alpha.52) (2024-03-29)
138
+
139
+
140
+ ### :bug: Bug Fix
141
+
142
+ * custom-alert in @operato/shell ([e628af8](https://github.com/hatiolab/operato/commit/e628af8d923de49960bfbcd04452b428105c0bc8))
143
+ * renovation CustomAlert ([757f04f](https://github.com/hatiolab/operato/commit/757f04f44bdb50e087ecacdbf217f3d3b20e922c))
144
+
145
+
146
+
147
+ ## [2.0.0-alpha.51](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.50...v2.0.0-alpha.51) (2024-03-29)
148
+
149
+
150
+ ### :bug: Bug Fix
151
+
152
+ * upgrade lit ([e661c33](https://github.com/hatiolab/operato/commit/e661c333d2bb97f784b5ac2c0e365714ee5e80ff))
153
+
154
+
155
+
156
+ ## [2.0.0-alpha.48](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.47...v2.0.0-alpha.48) (2024-03-28)
157
+
158
+
159
+ ### :bug: Bug Fix
160
+
161
+ * 폼 select가 왼쪽으로 가려질때 점점 왼쪽으로 가는 현상 수정 ([281bf40](https://github.com/hatiolab/operato/commit/281bf40fc1d37c35d837ee18d4489ed9da5982c5))
162
+
163
+
164
+
165
+ ## [2.0.0-alpha.47](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.46...v2.0.0-alpha.47) (2024-03-27)
166
+
167
+ **Note:** Version bump only for package @operato/popup
168
+
169
+
170
+
171
+
172
+
173
+ ## [2.0.0-alpha.35](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.34...v2.0.0-alpha.35) (2024-03-13)
174
+
175
+ **Note:** Version bump only for package @operato/popup
176
+
177
+
178
+
179
+
180
+
181
+ ## [2.0.0-alpha.28](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.27...v2.0.0-alpha.28) (2024-02-20)
182
+
183
+
184
+ ### :bug: Bug Fix
185
+
186
+ * upgrade devDependencies for webcomponents ([1489b8b](https://github.com/hatiolab/operato/commit/1489b8b790d9bcee779a070a630697f25c01728f))
187
+
188
+
189
+
190
+ ## [2.0.0-alpha.9](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.8...v2.0.0-alpha.9) (2024-01-20)
191
+
192
+
193
+ ### :bug: Bug Fix
194
+
195
+ * use zbar-wasm for barcode scan ([41f632e](https://github.com/hatiolab/operato/commit/41f632e1e395e17364713e1ecb8f878615fc91ca))
196
+
197
+
198
+
199
+ ## [2.0.0-alpha.8](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.7...v2.0.0-alpha.8) (2024-01-20)
200
+
201
+
202
+ ### :bug: Bug Fix
203
+
204
+ * comment for libraries ([bdf20d0](https://github.com/hatiolab/operato/commit/bdf20d057819187106b4a9e37d25c2c1f7febb39))
205
+
206
+
207
+
208
+ ## [2.0.0-alpha.4](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.3...v2.0.0-alpha.4) (2024-01-15)
209
+
210
+
211
+ ### :bug: Bug Fix
212
+
213
+ * up z-index for ox-float-overlay ([57ff5ce](https://github.com/hatiolab/operato/commit/57ff5ceb0fd7dccbe5745e99a63f8cbba4a23ace))
214
+
215
+
216
+
217
+ ## [2.0.0-alpha.2](https://github.com/hatiolab/operato/compare/v2.0.0-alpha.1...v2.0.0-alpha.2) (2024-01-09)
218
+
219
+
220
+ ### :bug: Bug Fix
221
+
222
+ * typo event name 'context' => 'contextmenu' ([dcb6afa](https://github.com/hatiolab/operato/commit/dcb6afaafbfa9157b90b62a2f394ed71dcca3810))
223
+
224
+
225
+
6
226
  ## [2.0.0-alpha.0](https://github.com/hatiolab/operato/compare/v1.13.1...v2.0.0-alpha.0) (2024-01-05)
7
227
 
8
228
  **Note:** Version bump only for package @operato/popup
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>
@@ -25,7 +36,7 @@
25
36
  import { html, render } from 'lit'
26
37
  import '../dist/src/ox-popup-menu.js'
27
38
  import '../dist/src/ox-popup-menuitem.js'
28
- import '@material/mwc-icon'
39
+ import '@material/web/icon/icon.js'
29
40
  import '@operato/input/ox-checkbox.js'
30
41
 
31
42
  import { OxPopupMenu } from '../dist/src/ox-popup-menu.js'
@@ -41,11 +52,11 @@
41
52
  console.log('first level article selected')
42
53
  }}
43
54
  >
44
- <mwc-icon slot="icon">article</mwc-icon>
55
+ <md-icon slot="icon">article</md-icon>
45
56
  </ox-popup-menuitem>
46
57
 
47
58
  <ox-popup-menuitem label="home">
48
- <mwc-icon slot="icon">home</mwc-icon>
59
+ <md-icon slot="icon">home</md-icon>
49
60
  </ox-popup-menuitem>
50
61
 
51
62
  <ox-popup-menuitem label="empty"> </ox-popup-menuitem>
@@ -53,16 +64,16 @@
53
64
  <ox-popup-menuitem
54
65
  label="click me to toggle"
55
66
  @selected=${function (e) {
56
- const icon = this.querySelector('mwc-icon')
67
+ const icon = this.querySelector('md-icon')
57
68
  icon.innerHTML = icon.innerHTML == 'check' ? '' : 'check'
58
69
  }}
59
70
  alive-on-select
60
71
  >
61
- <mwc-icon slot="icon" style="width: 20px;height: 20px;"></mwc-icon>
72
+ <md-icon slot="icon" style="width: 20px;height: 20px;"></md-icon>
62
73
  </ox-popup-menuitem>
63
74
 
64
75
  <ox-popup-menuitem label="verified" @selected=${e => console.log('selected verified')}>
65
- <mwc-icon slot="icon">verified</mwc-icon>
76
+ <md-icon slot="icon">verified</md-icon>
66
77
  <ox-popup-menu>
67
78
  <ox-popup-menuitem
68
79
  label="article"
@@ -71,26 +82,26 @@
71
82
  }}
72
83
  alive-on-select
73
84
  >
74
- <mwc-icon slot="icon">article</mwc-icon>
85
+ <md-icon slot="icon">article</md-icon>
75
86
  </ox-popup-menuitem>
76
87
 
77
88
  <ox-popup-menuitem label="home">
78
- <mwc-icon slot="icon">home</mwc-icon>
89
+ <md-icon slot="icon">home</md-icon>
79
90
  </ox-popup-menuitem>
80
91
 
81
92
  <ox-popup-menuitem label="verified">
82
- <mwc-icon slot="icon">verified</mwc-icon>
93
+ <md-icon slot="icon">verified</md-icon>
83
94
  <ox-popup-menu>
84
95
  <ox-popup-menuitem label="article">
85
- <mwc-icon slot="icon">article</mwc-icon>
96
+ <md-icon slot="icon">article</md-icon>
86
97
  </ox-popup-menuitem>
87
98
 
88
99
  <ox-popup-menuitem label="home">
89
- <mwc-icon slot="icon">home</mwc-icon>
100
+ <md-icon slot="icon">home</md-icon>
90
101
  </ox-popup-menuitem>
91
102
 
92
103
  <ox-popup-menuitem label="verified">
93
- <mwc-icon slot="icon">verified</mwc-icon>
104
+ <md-icon slot="icon">verified</md-icon>
94
105
  </ox-popup-menuitem>
95
106
 
96
107
  <ox-popup-menuitem label="checkbox">
@@ -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" />
@@ -26,7 +26,18 @@
26
26
  }
27
27
  </style>
28
28
  <link href="https://fonts.googleapis.com/css?family=Roboto:300,400,500" rel="stylesheet" />
29
- <link href="https://fonts.googleapis.com/css?family=Material+Icons&display=block" rel="stylesheet" />
29
+ <link
30
+ href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL@20..48,100..700,0..1"
31
+ rel="stylesheet"
32
+ />
33
+ <link
34
+ href="https://fonts.googleapis.com/css2?family=Material+Symbols+Rounded:opsz,wght,FILL@20..48,100..700,0..1"
35
+ rel="stylesheet"
36
+ />
37
+ <link
38
+ href="https://fonts.googleapis.com/css2?family=Material+Symbols+Sharp:opsz,wght,FILL@20..48,100..700,0..1"
39
+ rel="stylesheet"
40
+ />
30
41
  </head>
31
42
  <body>
32
43
  <div id="demo-container">
@@ -37,7 +48,7 @@
37
48
  <script type="module">
38
49
  import { html, render } from 'lit'
39
50
  import '../dist/src/ox-popup-list.js'
40
- import '@material/mwc-icon'
51
+ import '@material/web/icon/icon.js'
41
52
  import '@operato/input/ox-checkbox.js'
42
53
 
43
54
  import { OxPopupList } from '../dist/src/ox-popup-list.js'
@@ -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>
@@ -25,7 +36,7 @@
25
36
  import { html, render } from 'lit'
26
37
  import '../dist/src/ox-popup-menu.js'
27
38
  import '../dist/src/ox-popup-menuitem.js'
28
- import '@material/mwc-icon'
39
+ import '@material/web/icon/icon.js'
29
40
  import '@operato/input/ox-checkbox.js'
30
41
 
31
42
  import { OxPopupMenu } from '../dist/src/ox-popup-menu.js'
@@ -41,11 +52,11 @@
41
52
  console.log('first level article selected')
42
53
  }}
43
54
  >
44
- <mwc-icon slot="icon">article</mwc-icon>
55
+ <md-icon slot="icon">article</md-icon>
45
56
  </ox-popup-menuitem>
46
57
 
47
58
  <ox-popup-menuitem label="home">
48
- <mwc-icon slot="icon">home</mwc-icon>
59
+ <md-icon slot="icon">home</md-icon>
49
60
  </ox-popup-menuitem>
50
61
 
51
62
  <ox-popup-menuitem label="empty"> </ox-popup-menuitem>
@@ -53,16 +64,16 @@
53
64
  <ox-popup-menuitem
54
65
  label="click me to toggle"
55
66
  @selected=${function (e) {
56
- const icon = this.querySelector('mwc-icon')
67
+ const icon = this.querySelector('md-icon')
57
68
  icon.innerHTML = icon.innerHTML == 'check' ? '' : 'check'
58
69
  }}
59
70
  alive-on-select
60
71
  >
61
- <mwc-icon slot="icon" style="width: 20px;height: 20px;"></mwc-icon>
72
+ <md-icon slot="icon" style="width: 20px;height: 20px;"></md-icon>
62
73
  </ox-popup-menuitem>
63
74
 
64
75
  <ox-popup-menuitem label="verified" @selected=${e => console.log('selected verified')}>
65
- <mwc-icon slot="icon">verified</mwc-icon>
76
+ <md-icon slot="icon">verified</md-icon>
66
77
  <ox-popup-menu>
67
78
  <ox-popup-menuitem
68
79
  label="article"
@@ -71,26 +82,26 @@
71
82
  }}
72
83
  alive-on-select
73
84
  >
74
- <mwc-icon slot="icon">article</mwc-icon>
85
+ <md-icon slot="icon">article</md-icon>
75
86
  </ox-popup-menuitem>
76
87
 
77
88
  <ox-popup-menuitem label="home">
78
- <mwc-icon slot="icon">home</mwc-icon>
89
+ <md-icon slot="icon">home</md-icon>
79
90
  </ox-popup-menuitem>
80
91
 
81
92
  <ox-popup-menuitem label="verified">
82
- <mwc-icon slot="icon">verified</mwc-icon>
93
+ <md-icon slot="icon">verified</md-icon>
83
94
  <ox-popup-menu>
84
95
  <ox-popup-menuitem label="article">
85
- <mwc-icon slot="icon">article</mwc-icon>
96
+ <md-icon slot="icon">article</md-icon>
86
97
  </ox-popup-menuitem>
87
98
 
88
99
  <ox-popup-menuitem label="home">
89
- <mwc-icon slot="icon">home</mwc-icon>
100
+ <md-icon slot="icon">home</md-icon>
90
101
  </ox-popup-menuitem>
91
102
 
92
103
  <ox-popup-menuitem label="verified">
93
- <mwc-icon slot="icon">verified</mwc-icon>
104
+ <md-icon slot="icon">verified</md-icon>
94
105
  </ox-popup-menuitem>
95
106
 
96
107
  <ox-popup-menuitem label="checkbox">
@@ -1,33 +1,94 @@
1
- import '@material/mwc-icon';
1
+ import '@material/web/icon/icon.js';
2
2
  import { LitElement, PropertyValues } from 'lit';
3
+ /**
4
+ * Custom element for creating floating overlays.
5
+ * These overlays can have various properties like direction, size, title, and more.
6
+ * They are often used for modal dialogs, pop-ups, and similar UI elements.
7
+ */
3
8
  export declare class OxFloatingOverlay extends LitElement {
4
9
  static styles: import("lit").CSSResult[];
10
+ /**
11
+ * A boolean property that determines whether a backdrop should be displayed behind the overlay.
12
+ * Backdrop provides a semi-transparent background that covers the entire screen when the overlay is open.
13
+ */
5
14
  backdrop?: boolean;
15
+ /**
16
+ * A string property that specifies the direction in which the overlay should appear.
17
+ * Possible values are: 'up', 'down', 'left', or 'right'.
18
+ */
6
19
  direction?: 'up' | 'down' | 'left' | 'right';
20
+ /**
21
+ * A string property that reflects the hovering state of the overlay.
22
+ * Possible values are: 'center', 'edge', or 'next'.
23
+ */
7
24
  hovering?: 'center' | 'edge' | 'next';
25
+ /**
26
+ * A string property that specifies the size of the overlay.
27
+ * Possible values are: 'small', 'medium', or 'large'.
28
+ */
8
29
  size?: 'small' | 'medium' | 'large';
30
+ /**
31
+ * A string property that represents the name of the overlay.
32
+ * This can be used for identification or other purposes.
33
+ */
9
34
  name?: string;
35
+ /**
36
+ * A string property that sets the title of the overlay.
37
+ * The title is typically displayed in the header of the overlay.
38
+ */
10
39
  title: string;
40
+ /**
41
+ * A boolean property that determines whether the overlay can be closed by the user.
42
+ * If set to true, a close button will be displayed in the header.
43
+ */
11
44
  closable?: boolean;
45
+ /**
46
+ * An object property that can hold custom properties for the template of the overlay.
47
+ * These properties can be used to customize the template's behavior.
48
+ */
12
49
  templateProperties: any;
50
+ /**
51
+ * An object property that can hold information related to help or assistance for the overlay.
52
+ * This information may be used to provide additional guidance to users.
53
+ */
13
54
  help: any;
55
+ /**
56
+ * A boolean property that determines whether the overlay is considered historical.
57
+ * Historical overlays may have specific behavior or interactions, such as navigating back in history.
58
+ */
14
59
  historical?: boolean;
60
+ /**
61
+ * A boolean property that determines whether the overlay can be moved by dragging.
62
+ * If set to true, the overlay can be repositioned by dragging its header.
63
+ */
15
64
  movable?: boolean;
65
+ /**
66
+ * An object property that can hold information related to a search feature within the overlay.
67
+ * It can include properties like 'value', 'handler', and 'placeholder'.
68
+ */
16
69
  search?: {
17
70
  value?: string;
18
71
  handler?: (instance: any, value: string) => void;
19
72
  placeholder?: string;
20
73
  };
74
+ /**
75
+ * An object property that can hold information related to a filter feature within the overlay.
76
+ * It can include a 'handler' function for filtering content.
77
+ */
21
78
  filter?: {
22
79
  handler?: (instance: any) => void;
23
80
  };
81
+ /**
82
+ * A numeric property that specifies the z-index of the overlay.
83
+ * The z-index determines the stacking order of the overlay in relation to other elements on the page.
84
+ */
24
85
  zIndex?: number;
25
86
  private dragStart?;
26
87
  private dragEndHandler;
27
88
  private dragMoveHandler;
28
89
  overlayed: HTMLDivElement;
29
90
  content: HTMLDivElement;
30
- render(): import("lit").TemplateResult<1>;
91
+ render(): import("lit-html").TemplateResult<1>;
31
92
  updated(changes: PropertyValues<this>): void;
32
93
  firstUpdated(): void;
33
94
  connectedCallback(): void;
@@ -35,6 +96,10 @@ export declare class OxFloatingOverlay extends LitElement {
35
96
  onDragStart(e: Event): false | undefined;
36
97
  onDragMove(e: Event): boolean;
37
98
  onDragEnd(e: Event): void;
99
+ /**
100
+ * A method that closes the overlay by removing it from its parent node in the DOM.
101
+ * When called, this method removes the overlay element, effectively hiding it from the user interface.
102
+ */
38
103
  close(): void;
39
104
  onClose(e: Event, escape?: boolean): true | undefined;
40
105
  }
@@ -1,5 +1,5 @@
1
1
  import { __decorate } from "tslib";
2
- import '@material/mwc-icon';
2
+ import '@material/web/icon/icon.js';
3
3
  import { css, html, LitElement } from 'lit';
4
4
  import { customElement, property, query } from 'lit/decorators.js';
5
5
  import { ifDefined } from 'lit/directives/if-defined.js';
@@ -24,13 +24,38 @@ function getPoint(e) {
24
24
  return;
25
25
  }
26
26
  }
27
+ /**
28
+ * Custom element for creating floating overlays.
29
+ * These overlays can have various properties like direction, size, title, and more.
30
+ * They are often used for modal dialogs, pop-ups, and similar UI elements.
31
+ */
27
32
  let OxFloatingOverlay = class OxFloatingOverlay extends LitElement {
28
33
  constructor() {
29
34
  super(...arguments);
35
+ /**
36
+ * A boolean property that determines whether a backdrop should be displayed behind the overlay.
37
+ * Backdrop provides a semi-transparent background that covers the entire screen when the overlay is open.
38
+ */
30
39
  this.backdrop = false;
40
+ /**
41
+ * A string property that sets the title of the overlay.
42
+ * The title is typically displayed in the header of the overlay.
43
+ */
31
44
  this.title = '';
45
+ /**
46
+ * A boolean property that determines whether the overlay can be closed by the user.
47
+ * If set to true, a close button will be displayed in the header.
48
+ */
32
49
  this.closable = false;
50
+ /**
51
+ * A boolean property that determines whether the overlay is considered historical.
52
+ * Historical overlays may have specific behavior or interactions, such as navigating back in history.
53
+ */
33
54
  this.historical = false;
55
+ /**
56
+ * A boolean property that determines whether the overlay can be moved by dragging.
57
+ * If set to true, the overlay can be repositioned by dragging its header.
58
+ */
34
59
  this.movable = false;
35
60
  this.dragEndHandler = this.onDragEnd.bind(this);
36
61
  this.dragMoveHandler = this.onDragMove.bind(this);
@@ -82,8 +107,8 @@ let OxFloatingOverlay = class OxFloatingOverlay extends LitElement {
82
107
  @touchstart=${this.onDragStart.bind(this)}
83
108
  draggable="false"
84
109
  >
85
- <mwc-icon @click=${(e) => this.onClose(e)} ?closable=${this.closable} historyback>arrow_back</mwc-icon>
86
- ${this.movable ? html `<mwc-icon>drag_indicator</mwc-icon>` : html ``}
110
+ <md-icon @click=${(e) => this.onClose(e)} ?closable=${this.closable} historyback>arrow_back</md-icon>
111
+ ${this.movable ? html `<md-icon>drag_indicator</md-icon>` : html ``}
87
112
  <slot name="header">
88
113
  ${this.title || this.closable
89
114
  ? html `
@@ -109,9 +134,7 @@ let OxFloatingOverlay = class OxFloatingOverlay extends LitElement {
109
134
  : html ``}
110
135
  ${this.help && searchable ? html `<ox-help-icon .topic=${this.help}></ox-help-icon>` : html ``}
111
136
  ${filterable
112
- ? html `<mwc-icon @click=${(e) => filterHandler(this.firstElementChild)}
113
- >tune</mwc-icon
114
- >`
137
+ ? html `<md-icon @click=${(e) => filterHandler(this.firstElementChild)}>tune</md-icon>`
115
138
  : html ``}
116
139
  </div>
117
140
  `
@@ -120,7 +143,7 @@ let OxFloatingOverlay = class OxFloatingOverlay extends LitElement {
120
143
  ? html `<ox-help-icon .topic=${this.help}></ox-help-icon>`
121
144
  : html ``}
122
145
  </slot>
123
- <mwc-icon @click=${(e) => this.onClose(e)} ?closable=${this.closable} close>close</mwc-icon>
146
+ <md-icon @click=${(e) => this.onClose(e)} ?closable=${this.closable} close>close</md-icon>
124
147
  </div>
125
148
 
126
149
  <div content>
@@ -215,6 +238,10 @@ let OxFloatingOverlay = class OxFloatingOverlay extends LitElement {
215
238
  delete this.dragStart;
216
239
  }
217
240
  }
241
+ /**
242
+ * A method that closes the overlay by removing it from its parent node in the DOM.
243
+ * When called, this method removes the overlay element, effectively hiding it from the user interface.
244
+ */
218
245
  close() {
219
246
  var _a;
220
247
  (_a = this.parentNode) === null || _a === void 0 ? void 0 : _a.removeChild(this);
@@ -245,7 +272,7 @@ OxFloatingOverlay.styles = [
245
272
  /* for layout style */
246
273
  :host {
247
274
  position: relative;
248
- z-index: var(--z-index, 1);
275
+ z-index: var(--z-index, 10);
249
276
  }
250
277
 
251
278
  :host([hovering='edge']) {