@spectrum-web-components/split-view 0.4.4-express.9 → 0.4.4

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spectrum-web-components/split-view",
3
- "version": "0.4.4-express.9+abfee7409",
3
+ "version": "0.4.4",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -44,16 +44,16 @@
44
44
  "lit-html"
45
45
  ],
46
46
  "dependencies": {
47
- "@spectrum-web-components/base": "^0.5.2",
47
+ "@spectrum-web-components/base": "^0.5.3",
48
48
  "tslib": "^2.0.0"
49
49
  },
50
50
  "devDependencies": {
51
- "@spectrum-css/splitview": "^3.0.13"
51
+ "@spectrum-css/splitview": "^3.0.14"
52
52
  },
53
53
  "types": "./src/index.d.ts",
54
54
  "customElements": "custom-elements.json",
55
55
  "sideEffects": [
56
56
  "./sp-*.js"
57
57
  ],
58
- "gitHead": "abfee740957976448a3e4cf90df17d6165f857d6"
58
+ "gitHead": "57aba8030b6af96af4015a0aa830e342a17dc219"
59
59
  }
@@ -1,296 +0,0 @@
1
- /*
2
- Copyright 2020 Adobe. All rights reserved.
3
- This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License. You may obtain a copy
5
- of the License at http://www.apache.org/licenses/LICENSE-2.0
6
-
7
- Unless required by applicable law or agreed to in writing, software distributed under
8
- the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- OF ANY KIND, either express or implied. See the License for the specific language
10
- governing permissions and limitations under the License.
11
- */
12
- import { html } from '@spectrum-web-components/base';
13
- import '../sp-split-view.js';
14
- export default {
15
- title: 'Split View',
16
- component: 'sp-split-view',
17
- args: {
18
- primarySize: 100,
19
- },
20
- argTypes: {
21
- primarySize: {
22
- name: 'primarySize',
23
- type: { name: 'number', required: false },
24
- description: 'Size of the primary panel.',
25
- table: {
26
- type: { summary: 'number' },
27
- defaultValue: { summary: undefined },
28
- },
29
- control: {
30
- type: 'number',
31
- },
32
- },
33
- },
34
- };
35
- export const Horizontal = (args) => {
36
- return html `
37
- <sp-split-view style="height: 200px" .primarySize="${args.primarySize}">
38
- <div>First panel</div>
39
- <div>Second panel</div>
40
- </sp-split-view>
41
- `;
42
- };
43
- export const HorizontalResizable = (args) => {
44
- return html `
45
- <sp-split-view
46
- resizable
47
- primary-min="50"
48
- .primarySize="${args.primarySize}"
49
- secondary-min="50"
50
- >
51
- <div>
52
- <h1>First panel</h1>
53
- <p>
54
- Lorem Ipsum is simply dummy text of the printing and
55
- typesetting industry.
56
- </p>
57
- </div>
58
- <div>
59
- <h2>Second panel</h2>
60
- <p>
61
- It is a long established fact that a reader will be
62
- distracted by the readable content of a page when looking at
63
- its layout.
64
- </p>
65
- </div>
66
- </sp-split-view>
67
- `;
68
- };
69
- export const HorizontalResizableCollapsible = (args) => {
70
- return html `
71
- <sp-split-view
72
- resizable
73
- collapsible
74
- primary-min="50"
75
- secondary-min="50"
76
- style="height: 500px;"
77
- .primarySize="${args.primarySize}"
78
- >
79
- <div>
80
- <h1>First panel</h1>
81
- <p>
82
- Lorem Ipsum is simply dummy text of the printing and
83
- typesetting industry. Lorem Ipsum has been the industry's
84
- standard dummy text ever since the 1500s, when an unknown
85
- printer took a galley of type and scrambled it to make a
86
- type specimen book. It has survived not only five centuries,
87
- but also the leap into electronic typesetting, remaining
88
- essentially unchanged. It was popularised in the 1960s with
89
- the release of Letraset sheets containing Lorem Ipsum
90
- passages, and more recently with desktop publishing software
91
- like Aldus PageMaker including versions of Lorem Ipsum.
92
- </p>
93
- </div>
94
- <div>
95
- <h2>Second panel</h2>
96
- <p>
97
- It is a long established fact that a reader will be
98
- distracted by the readable content of a page when looking at
99
- its layout. The point of using Lorem Ipsum is that it has a
100
- more-or-less normal distribution of letters, as opposed to
101
- using 'Content here, content here', making it look like
102
- readable English. Many desktop publishing packages and web
103
- page editors now use Lorem Ipsum as their default model
104
- text, and a search for 'lorem ipsum' will uncover many web
105
- sites still in their infancy. Various versions have evolved
106
- over the years, sometimes by accident, sometimes on purpose
107
- (injected humour and the like).
108
- </p>
109
- </div>
110
- </sp-split-view>
111
- `;
112
- };
113
- HorizontalResizableCollapsible.args = {
114
- primarySize: undefined,
115
- };
116
- export const Vertical = (args) => {
117
- return html `
118
- <sp-split-view vertical .primarySize="${args.primarySize}">
119
- <div>First panel</div>
120
- <div>Second panel</div>
121
- </sp-split-view>
122
- `;
123
- };
124
- Vertical.args = {
125
- primarySize: undefined,
126
- };
127
- export const VerticalResizable = (args) => {
128
- return html `
129
- <sp-split-view
130
- vertical
131
- resizable
132
- primary-min="50"
133
- primary-max="100"
134
- secondary-min="50"
135
- style="height: 400px;"
136
- .primarySize="${args.primarySize}"
137
- >
138
- <div>
139
- <h1>First panel</h1>
140
- <p>
141
- Lorem Ipsum is simply dummy text of the printing and
142
- typesetting industry. Lorem Ipsum has been the industry's
143
- standard dummy text ever since the 1500s, when an unknown
144
- printer took a galley of type and scrambled it to make a
145
- type specimen book. It has survived not only five centuries,
146
- but also the leap into electronic typesetting, remaining
147
- essentially unchanged. It was popularised in the 1960s with
148
- the release of Letraset sheets containing Lorem Ipsum
149
- passages, and more recently with desktop publishing software
150
- like Aldus PageMaker including versions of Lorem Ipsum.
151
- </p>
152
- </div>
153
- <div>
154
- <h2>Second panel</h2>
155
- <p>
156
- It is a long established fact that a reader will be
157
- distracted by the readable content of a page when looking at
158
- its layout. The point of using Lorem Ipsum is that it has a
159
- more-or-less normal distribution of letters, as opposed to
160
- using 'Content here, content here', making it look like
161
- readable English. Many desktop publishing packages and web
162
- page editors now use Lorem Ipsum as their default model
163
- text, and a search for 'lorem ipsum' will uncover many web
164
- sites still in their infancy. Various versions have evolved
165
- over the years, sometimes by accident, sometimes on purpose
166
- (injected humour and the like).
167
- </p>
168
- </div>
169
- </sp-split-view>
170
- `;
171
- };
172
- VerticalResizable.args = {
173
- primarySize: undefined,
174
- };
175
- export const VerticalResizableCollapsible = (args) => {
176
- return html `
177
- <sp-split-view
178
- vertical
179
- resizable
180
- collapsible
181
- primary-min="50"
182
- secondary-min="40"
183
- style="height: 400px;"
184
- .primarySize="${args.primarySize}"
185
- >
186
- <div>
187
- <h1>First panel</h1>
188
- <p>
189
- Lorem Ipsum is simply dummy text of the printing and
190
- typesetting industry. Lorem Ipsum has been the industry's
191
- standard dummy text ever since the 1500s, when an unknown
192
- printer took a galley of type and scrambled it to make a
193
- type specimen book. It has survived not only five centuries,
194
- but also the leap into electronic typesetting, remaining
195
- essentially unchanged. It was popularised in the 1960s with
196
- the release of Letraset sheets containing Lorem Ipsum
197
- passages, and more recently with desktop publishing software
198
- like Aldus PageMaker including versions of Lorem Ipsum.
199
- </p>
200
- </div>
201
- <div>
202
- <h2>Second panel</h2>
203
- <p>
204
- It is a long established fact that a reader will be
205
- distracted by the readable content of a page when looking at
206
- its layout. The point of using Lorem Ipsum is that it has a
207
- more-or-less normal distribution of letters, as opposed to
208
- using 'Content here, content here', making it look like
209
- readable English. Many desktop publishing packages and web
210
- page editors now use Lorem Ipsum as their default model
211
- text, and a search for 'lorem ipsum' will uncover many web
212
- sites still in their infancy. Various versions have evolved
213
- over the years, sometimes by accident, sometimes on purpose
214
- (injected humour and the like).
215
- </p>
216
- </div>
217
- </sp-split-view>
218
- `;
219
- };
220
- VerticalResizableCollapsible.args = {
221
- primarySize: 250,
222
- };
223
- export const MultipleLevels = (args) => {
224
- return html `
225
- <sp-split-view
226
- resizable
227
- primary-min="50"
228
- primary-max="200"
229
- secondary-min="50"
230
- style="height: 400px; width: 600px;"
231
- >
232
- <div>
233
- <h1>First panel - Level 1</h1>
234
- <p>
235
- Lorem Ipsum is simply dummy text of the printing and
236
- typesetting industry. Lorem Ipsum has been the industry's
237
- standard dummy text ever since the 1500s, when an unknown
238
- printer took a galley of type and scrambled it to make a
239
- type specimen book. It has survived not only five centuries,
240
- but also the leap into electronic typesetting, remaining
241
- essentially unchanged. It was popularised in the 1960s with
242
- the release of Letraset sheets containing Lorem Ipsum
243
- passages, and more recently with desktop publishing software
244
- like Aldus PageMaker including versions of Lorem Ipsum.
245
- </p>
246
- </div>
247
- <div>
248
- <h2>Second panel - Level 1</h2>
249
- <sp-split-view
250
- vertical
251
- resizable
252
- primary-min="50"
253
- .primarySize="${args.primarySize}"
254
- secondary-min="50"
255
- style="height: 300px;"
256
- >
257
- <div>
258
- <h3>First panel - Level 2</h3>
259
- <p>
260
- Lorem Ipsum is simply dummy text of the printing and
261
- typesetting industry.
262
- </p>
263
- </div>
264
- <div>
265
- <h4>Second panel - Level 2</h4>
266
- <p>
267
- It is a long established fact that a reader will be
268
- distracted by the readable content of a page when
269
- looking at its layout.
270
- </p>
271
- </div>
272
- </sp-split-view>
273
- </div>
274
- </sp-split-view>
275
- `;
276
- };
277
- export const OnePaneNoSplitter = (args) => {
278
- return html `
279
- <sp-split-view style="height: 200px" .primarySize="${args.primarySize}">
280
- <div>First panel</div>
281
- </sp-split-view>
282
- `;
283
- };
284
- export const ShowFirstTwoPanes = (args) => {
285
- return html `
286
- <sp-split-view style="height: 200px" .primarySize="${args.primarySize}">
287
- <div>First panel</div>
288
- <div>Second panel</div>
289
- <div>Third (invisible) panel</div>
290
- </sp-split-view>
291
- `;
292
- };
293
- ShowFirstTwoPanes.args = {
294
- primarySize: undefined,
295
- };
296
- //# sourceMappingURL=split-view.stories.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"split-view.stories.js","sourceRoot":"","sources":["split-view.stories.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;AAEF,OAAO,EAAE,IAAI,EAAkB,MAAM,+BAA+B,CAAC;AAErE,OAAO,qBAAqB,CAAC;AAE7B,eAAe;IACX,KAAK,EAAE,YAAY;IACnB,SAAS,EAAE,eAAe;IAC1B,IAAI,EAAE;QACF,WAAW,EAAE,GAAG;KACnB;IACD,QAAQ,EAAE;QACN,WAAW,EAAE;YACT,IAAI,EAAE,aAAa;YACnB,IA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;;;;;;;;;;KAkCvC,CAAC;AACN,CAAC,CAAC;AAEF,iBAAiB,CAAC,IAAI,GAAG;IACrB,WAAW,EAAE,SAAS;CACzB,CAAC;AAEF,MAAM,CAAC,MAAM,4BAA4B,GAAG,CACxC,IAAgB,EACF,EAAE;IAChB,OAAO,IAAI,CAAA;;;;;;;;4BAQa,IAAI,CAAC,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAkCvC,CAAC;AACN,CAAC,CAAC;AAEF,4BAA4B,CAAC,IAAI,GAAG;IAChC,WAAW,EAAE,GAAG;CACnB,CAAC;AAEF,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,IAAgB,EAAkB,EAAE;IAC/D,OAAO,IAAI,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oCA6BqB,IAAI,CAAC,WAAW;;;;;;;;;;;;;;;;;;;;;;KAsB/C,CAAC;AACN,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,IAAgB,EAAkB,EAAE;IAClE,OAAO,IAAI,CAAA;6DAC8C,IAAI,CAAC,WAAW;;;KAGxE,CAAC;AACN,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,IAAgB,EAAkB,EAAE;IAClE,OAAO,IAAI,CAAA;6DAC8C,IAAI,CAAC,WAAW;;;;;KAKxE,CAAC;AACN,CAAC,CAAC;AAEF,iBAAiB,CAAC,IAAI,GAAG;IACrB,WAAW,EAAE,SAAS;CACzB,CAAC","sourcesContent":["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport { html, TemplateResult } from '@spectrum-web-components/base';\n\nimport '../sp-split-view.js';\n\nexport default {\n title: 'Split View',\n component: 'sp-split-view',\n args: {\n primarySize: 100,\n },\n argTypes: {\n primarySize: {\n name: 'primarySize',\n type: { name: 'number', required: false },\n description: 'Size of the primary panel.',\n table: {\n type: { summary: 'number' },\n defaultValue: { summary: undefined },\n },\n control: {\n type: 'number',\n },\n },\n },\n};\n\ninterface Properties {\n primarySize?: string;\n}\n\nexport const Horizontal = (args: Properties): TemplateResult => {\n return html`\n <sp-split-view style=\"height: 200px\" .primarySize=\"${args.primarySize}\">\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `;\n};\n\nexport const HorizontalResizable = (args: Properties): TemplateResult => {\n return html`\n <sp-split-view\n resizable\n primary-min=\"50\"\n .primarySize=\"${args.primarySize}\"\n secondary-min=\"50\"\n >\n <div>\n <h1>First panel</h1>\n <p>\n Lorem Ipsum is simply dummy text of the printing and\n typesetting industry.\n </p>\n </div>\n <div>\n <h2>Second panel</h2>\n <p>\n It is a long established fact that a reader will be\n distracted by the readable content of a page when looking at\n its layout.\n </p>\n </div>\n </sp-split-view>\n `;\n};\n\nexport const HorizontalResizableCollapsible = (\n args: Properties\n): TemplateResult => {\n return html`\n <sp-split-view\n resizable\n collapsible\n primary-min=\"50\"\n secondary-min=\"50\"\n style=\"height: 500px;\"\n .primarySize=\"${args.primarySize}\"\n >\n <div>\n <h1>First panel</h1>\n <p>\n Lorem Ipsum is simply dummy text of the printing and\n typesetting industry. Lorem Ipsum has been the industry's\n standard dummy text ever since the 1500s, when an unknown\n printer took a galley of type and scrambled it to make a\n type specimen book. It has survived not only five centuries,\n but also the leap into electronic typesetting, remaining\n essentially unchanged. It was popularised in the 1960s with\n the release of Letraset sheets containing Lorem Ipsum\n passages, and more recently with desktop publishing software\n like Aldus PageMaker including versions of Lorem Ipsum.\n </p>\n </div>\n <div>\n <h2>Second panel</h2>\n <p>\n It is a long established fact that a reader will be\n distracted by the readable content of a page when looking at\n its layout. The point of using Lorem Ipsum is that it has a\n more-or-less normal distribution of letters, as opposed to\n using 'Content here, content here', making it look like\n readable English. Many desktop publishing packages and web\n page editors now use Lorem Ipsum as their default model\n text, and a search for 'lorem ipsum' will uncover many web\n sites still in their infancy. Various versions have evolved\n over the years, sometimes by accident, sometimes on purpose\n (injected humour and the like).\n </p>\n </div>\n </sp-split-view>\n `;\n};\n\nHorizontalResizableCollapsible.args = {\n primarySize: undefined,\n};\n\nexport const Vertical = (args: Properties): TemplateResult => {\n return html`\n <sp-split-view vertical .primarySize=\"${args.primarySize}\">\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `;\n};\n\nVertical.args = {\n primarySize: undefined,\n};\n\nexport const VerticalResizable = (args: Properties): TemplateResult => {\n return html`\n <sp-split-view\n vertical\n resizable\n primary-min=\"50\"\n primary-max=\"100\"\n secondary-min=\"50\"\n style=\"height: 400px;\"\n .primarySize=\"${args.primarySize}\"\n >\n <div>\n <h1>First panel</h1>\n <p>\n Lorem Ipsum is simply dummy text of the printing and\n typesetting industry. Lorem Ipsum has been the industry's\n standard dummy text ever since the 1500s, when an unknown\n printer took a galley of type and scrambled it to make a\n type specimen book. It has survived not only five centuries,\n but also the leap into electronic typesetting, remaining\n essentially unchanged. It was popularised in the 1960s with\n the release of Letraset sheets containing Lorem Ipsum\n passages, and more recently with desktop publishing software\n like Aldus PageMaker including versions of Lorem Ipsum.\n </p>\n </div>\n <div>\n <h2>Second panel</h2>\n <p>\n It is a long established fact that a reader will be\n distracted by the readable content of a page when looking at\n its layout. The point of using Lorem Ipsum is that it has a\n more-or-less normal distribution of letters, as opposed to\n using 'Content here, content here', making it look like\n readable English. Many desktop publishing packages and web\n page editors now use Lorem Ipsum as their default model\n text, and a search for 'lorem ipsum' will uncover many web\n sites still in their infancy. Various versions have evolved\n over the years, sometimes by accident, sometimes on purpose\n (injected humour and the like).\n </p>\n </div>\n </sp-split-view>\n `;\n};\n\nVerticalResizable.args = {\n primarySize: undefined,\n};\n\nexport const VerticalResizableCollapsible = (\n args: Properties\n): TemplateResult => {\n return html`\n <sp-split-view\n vertical\n resizable\n collapsible\n primary-min=\"50\"\n secondary-min=\"40\"\n style=\"height: 400px;\"\n .primarySize=\"${args.primarySize}\"\n >\n <div>\n <h1>First panel</h1>\n <p>\n Lorem Ipsum is simply dummy text of the printing and\n typesetting industry. Lorem Ipsum has been the industry's\n standard dummy text ever since the 1500s, when an unknown\n printer took a galley of type and scrambled it to make a\n type specimen book. It has survived not only five centuries,\n but also the leap into electronic typesetting, remaining\n essentially unchanged. It was popularised in the 1960s with\n the release of Letraset sheets containing Lorem Ipsum\n passages, and more recently with desktop publishing software\n like Aldus PageMaker including versions of Lorem Ipsum.\n </p>\n </div>\n <div>\n <h2>Second panel</h2>\n <p>\n It is a long established fact that a reader will be\n distracted by the readable content of a page when looking at\n its layout. The point of using Lorem Ipsum is that it has a\n more-or-less normal distribution of letters, as opposed to\n using 'Content here, content here', making it look like\n readable English. Many desktop publishing packages and web\n page editors now use Lorem Ipsum as their default model\n text, and a search for 'lorem ipsum' will uncover many web\n sites still in their infancy. Various versions have evolved\n over the years, sometimes by accident, sometimes on purpose\n (injected humour and the like).\n </p>\n </div>\n </sp-split-view>\n `;\n};\n\nVerticalResizableCollapsible.args = {\n primarySize: 250,\n};\n\nexport const MultipleLevels = (args: Properties): TemplateResult => {\n return html`\n <sp-split-view\n resizable\n primary-min=\"50\"\n primary-max=\"200\"\n secondary-min=\"50\"\n style=\"height: 400px; width: 600px;\"\n >\n <div>\n <h1>First panel - Level 1</h1>\n <p>\n Lorem Ipsum is simply dummy text of the printing and\n typesetting industry. Lorem Ipsum has been the industry's\n standard dummy text ever since the 1500s, when an unknown\n printer took a galley of type and scrambled it to make a\n type specimen book. It has survived not only five centuries,\n but also the leap into electronic typesetting, remaining\n essentially unchanged. It was popularised in the 1960s with\n the release of Letraset sheets containing Lorem Ipsum\n passages, and more recently with desktop publishing software\n like Aldus PageMaker including versions of Lorem Ipsum.\n </p>\n </div>\n <div>\n <h2>Second panel - Level 1</h2>\n <sp-split-view\n vertical\n resizable\n primary-min=\"50\"\n .primarySize=\"${args.primarySize}\"\n secondary-min=\"50\"\n style=\"height: 300px;\"\n >\n <div>\n <h3>First panel - Level 2</h3>\n <p>\n Lorem Ipsum is simply dummy text of the printing and\n typesetting industry.\n </p>\n </div>\n <div>\n <h4>Second panel - Level 2</h4>\n <p>\n It is a long established fact that a reader will be\n distracted by the readable content of a page when\n looking at its layout.\n </p>\n </div>\n </sp-split-view>\n </div>\n </sp-split-view>\n `;\n};\n\nexport const OnePaneNoSplitter = (args: Properties): TemplateResult => {\n return html`\n <sp-split-view style=\"height: 200px\" .primarySize=\"${args.primarySize}\">\n <div>First panel</div>\n </sp-split-view>\n `;\n};\n\nexport const ShowFirstTwoPanes = (args: Properties): TemplateResult => {\n return html`\n <sp-split-view style=\"height: 200px\" .primarySize=\"${args.primarySize}\">\n <div>First panel</div>\n <div>Second panel</div>\n <div>Third (invisible) panel</div>\n </sp-split-view>\n `;\n};\n\nShowFirstTwoPanes.args = {\n primarySize: undefined,\n};\n"]}
@@ -1,15 +0,0 @@
1
- /*
2
- Copyright 2020 Adobe. All rights reserved.
3
- This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License. You may obtain a copy
5
- of the License at http://www.apache.org/licenses/LICENSE-2.0
6
-
7
- Unless required by applicable law or agreed to in writing, software distributed under
8
- the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- OF ANY KIND, either express or implied. See the License for the specific language
10
- governing permissions and limitations under the License.
11
- */
12
- import * as stories from '../stories/split-view.stories.js';
13
- import { regressVisuals } from '../../../test/visual/test.js';
14
- regressVisuals('SplitViewStories', stories);
15
- //# sourceMappingURL=split-view.test-vrt.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"split-view.test-vrt.js","sourceRoot":"","sources":["split-view.test-vrt.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;AAEF,OAAO,KAAK,OAAO,MAAM,kCAAkC,CAAC;AAC5D,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAE9D,cAAc,CAAC,kBAAkB,EAAE,OAAO,CAAC,CAAC","sourcesContent":["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport * as stories from '../stories/split-view.stories.js';\nimport { regressVisuals } from '../../../test/visual/test.js';\n\nregressVisuals('SplitViewStories', stories);\n"]}
@@ -1,754 +0,0 @@
1
- /*
2
- Copyright 2020 Adobe. All rights reserved.
3
- This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License. You may obtain a copy
5
- of the License at http://www.apache.org/licenses/LICENSE-2.0
6
-
7
- Unless required by applicable law or agreed to in writing, software distributed under
8
- the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- OF ANY KIND, either express or implied. See the License for the specific language
10
- governing permissions and limitations under the License.
11
- */
12
- import { elementUpdated, expect, fixture, html } from '@open-wc/testing';
13
- import '../sp-split-view.js';
14
- import { arrowDownEvent, arrowLeftEvent, arrowRightEvent, arrowUpEvent, endEvent, homeEvent, pageDownEvent, pageUpEvent, shiftTabEvent, } from '../../../test/testing-helpers.js';
15
- import { spy } from 'sinon';
16
- describe('SplitView', () => {
17
- it('loads default (horizontal) split-view accessibly', async () => {
18
- const el = await fixture(html `
19
- <sp-split-view primary-size="100">
20
- <div>First panel</div>
21
- <div>Second panel</div>
22
- </sp-split-view>
23
- `);
24
- await elementUpdated(el);
25
- await expect(el).to.be.accessible();
26
- expect(el.splitterPos || 0).to.equal(100);
27
- expect(el.resizable).to.be.false;
28
- expect(el.collapsible).to.be.false;
29
- const gripper = el.shadowRoot.querySelector('#gripper');
30
- expect(gripper).to.be.null;
31
- const splitter = el.shadowRoot.querySelector('#splitter');
32
- expect(getComputedStyle(splitter).cursor).to.equal('auto');
33
- });
34
- it('loads horizontal [resizable] split-view accessibly', async () => {
35
- const el = await fixture(html `
36
- <sp-split-view resizable primary-size="100px">
37
- <div>First panel</div>
38
- <div>Second panel</div>
39
- </sp-split-view>
40
- `);
41
- await elementUpdated(el);
42
- await expect(el).to.be.accessible();
43
- expect(el.splitterPos || 0).to.equal(100);
44
- const gripper = el.shadowRoot.querySelector('#gripper');
45
- await expect(gripper).to.be.accessible();
46
- const splitter = el.shadowRoot.querySelector('#splitter');
47
- expect(getComputedStyle(splitter).cursor).to.equal('ew-resize');
48
- });
49
- it('loads [vertical] split-view accessibly', async () => {
50
- const el = await fixture(html `
51
- <sp-split-view
52
- vertical
53
- primary-size="75%"
54
- style="height: 400px"
55
- >
56
- <div>First panel</div>
57
- <div>Second panel</div>
58
- </sp-split-view>
59
- `);
60
- await elementUpdated(el);
61
- await expect(el).to.be.accessible();
62
- expect(el.splitterPos || 0).to.equal(300);
63
- const splitter = el.shadowRoot.querySelector('#splitter');
64
- expect(getComputedStyle(splitter).cursor).to.equal('auto');
65
- });
66
- it('loads [vertical] [resizable] split-view accessibly', async () => {
67
- const el = await fixture(html `
68
- <sp-split-view vertical resizable style="height: 400px">
69
- <div>First panel</div>
70
- <div>Second panel</div>
71
- </sp-split-view>
72
- `);
73
- await elementUpdated(el);
74
- await expect(el).to.be.accessible();
75
- expect(el.splitterPos || 0).to.equal(200);
76
- const splitter = el.shadowRoot.querySelector('#splitter');
77
- expect(getComputedStyle(splitter).cursor).to.equal('ns-resize');
78
- });
79
- it('set all panel values', async () => {
80
- const splitTotalWidth = 400;
81
- const el = await fixture(html `
82
- <sp-split-view
83
- resizable
84
- primary-min="50"
85
- primary-max="300"
86
- secondary-min="50"
87
- style=${`height: 500px; width: ${splitTotalWidth}px;`}
88
- >
89
- <div>First panel</div>
90
- <div>Second panel</div>
91
- </sp-split-view>
92
- `);
93
- await elementUpdated(el);
94
- expect(el.resizable).to.be.true;
95
- expect(el.primaryMin).to.equal(50);
96
- expect(el.primaryMax).to.equal(300);
97
- expect(el.secondaryMin).to.equal(50);
98
- expect(el.secondaryMax).to.equal(3840);
99
- });
100
- it('use auto height in primary pane', async () => {
101
- const splitTotalWidth = 400;
102
- const el = await fixture(html `
103
- <sp-split-view
104
- resizable
105
- primary-size="auto"
106
- style=${`height: 500px; width: ${splitTotalWidth}px;`}
107
- >
108
- <div>
109
- First panel Lorem Ipsum is simply dummy text of the
110
- printing and typesetting industry. Lorem Ipsum has been
111
- the industry's standard dummy text ever since the 1500s,
112
- when an unknown printer took a galley of type and
113
- scrambled it to make a type specimen book. It has
114
- survived not only five centuries, but also the leap into
115
- electronic typesetting, remaining essentially unchanged.
116
- </div>
117
- <div>Second panel</div>
118
- </sp-split-view>
119
- `);
120
- await elementUpdated(el);
121
- expect(el.resizable).to.be.true;
122
- expect(el.primarySize).to.equal('auto');
123
- expect(el.splitterPos || 0).to.equal(398);
124
- });
125
- it('resizes when pointer moves and resizable is enabled [ltr]', async () => {
126
- let pointerId = -1;
127
- const splitTotalWidth = 400;
128
- const el = await fixture(html `
129
- <sp-split-view
130
- resizable
131
- primary-min="50"
132
- secondary-min="50"
133
- style=${`height: 200px; width: ${splitTotalWidth}px;`}
134
- >
135
- <div>First panel</div>
136
- <div>Second panel</div>
137
- </sp-split-view>
138
- `);
139
- await elementUpdated(el);
140
- expect(el.resizable).to.be.true;
141
- const splitter = el.shadowRoot.querySelector('#splitter');
142
- splitter.setPointerCapture = (id) => (pointerId = id);
143
- splitter.releasePointerCapture = (id) => (pointerId = id);
144
- let pos = el.splitterPos;
145
- expect(el.splitterPos).to.equal(200);
146
- splitter.dispatchEvent(new PointerEvent('pointerdown', { pointerId: 1 }));
147
- await elementUpdated(el);
148
- expect(pointerId).to.equal(1);
149
- pos -= 10;
150
- splitter.dispatchEvent(new PointerEvent('pointermove', {
151
- clientX: pos,
152
- }));
153
- await elementUpdated(el);
154
- expect(Math.round(el.splitterPos)).to.equal(pos - el.getBoundingClientRect().left);
155
- // don't collapse to start
156
- splitter.dispatchEvent(new PointerEvent('pointermove', {
157
- clientX: 0,
158
- }));
159
- await elementUpdated(el);
160
- expect(el.splitterPos).to.equal(el.primaryMin);
161
- expect(getComputedStyle(splitter).cursor).to.equal('e-resize');
162
- // don't collapse to end
163
- splitter.dispatchEvent(new PointerEvent('pointermove', {
164
- clientX: splitTotalWidth,
165
- }));
166
- await elementUpdated(el);
167
- expect(el.splitterPos, '350 first time').to.equal(splitTotalWidth - el.secondaryMin);
168
- expect(getComputedStyle(splitter).cursor).to.equal('w-resize');
169
- splitter.dispatchEvent(new PointerEvent('pointerup'));
170
- await elementUpdated(el);
171
- // don't change anything when triggering mouseevent with right button click
172
- splitter.dispatchEvent(new MouseEvent('pointerdown', { button: 2, cancelable: true }));
173
- await elementUpdated(el);
174
- splitter.dispatchEvent(new PointerEvent('pointermove', {
175
- clientX: 0,
176
- }));
177
- expect(el.splitterPos, '350 second time, because right click').to.equal(splitTotalWidth - el.secondaryMin);
178
- });
179
- it('resizes when pointer moves and resizable is enabled [rtl]', async () => {
180
- let pointerId = -1;
181
- const splitTotalWidth = 400;
182
- const el = await fixture(html `
183
- <sp-split-view
184
- resizable
185
- primary-min="50"
186
- secondary-min="40"
187
- style=${`height: 200px; width: ${splitTotalWidth}px;`}
188
- dir="rtl"
189
- >
190
- <div>First panel</div>
191
- <div>Second panel</div>
192
- </sp-split-view>
193
- `);
194
- await elementUpdated(el);
195
- expect(el.resizable).to.be.true;
196
- const splitter = el.shadowRoot.querySelector('#splitter');
197
- splitter.setPointerCapture = (id) => (pointerId = id);
198
- splitter.releasePointerCapture = (id) => (pointerId = id);
199
- let pos = el.splitterPos || 0;
200
- splitter.dispatchEvent(new PointerEvent('pointerdown', { pointerId: 1 }));
201
- await elementUpdated(el);
202
- expect(pointerId).to.equal(1);
203
- pos = el.getBoundingClientRect().right - 100;
204
- splitter.dispatchEvent(new PointerEvent('pointermove', {
205
- clientX: pos,
206
- }));
207
- await elementUpdated(el);
208
- expect(Math.round(el.splitterPos || 0)).to.equal(el.getBoundingClientRect().right - pos);
209
- splitter.dispatchEvent(new PointerEvent('pointermove', {
210
- clientX: 0,
211
- }));
212
- await elementUpdated(el);
213
- expect(el.splitterPos || 0).to.equal(splitTotalWidth - el.secondaryMin);
214
- expect(getComputedStyle(splitter).cursor).to.equal('e-resize');
215
- splitter.dispatchEvent(new PointerEvent('pointermove', {
216
- clientX: el.getBoundingClientRect().right,
217
- }));
218
- await elementUpdated(el);
219
- expect(el.splitterPos || 0).to.equal(el.primaryMin);
220
- expect(getComputedStyle(splitter).cursor).to.equal('w-resize');
221
- });
222
- it('resizes to start pos when pointer moves in horizontal splitview', async () => {
223
- let pointerId = -1;
224
- const el = await fixture(html `
225
- <sp-split-view
226
- resizable
227
- secondary-min="50"
228
- style="height: 200px; width: 400px;"
229
- >
230
- <div>First panel</div>
231
- <div>Second panel</div>
232
- </sp-split-view>
233
- `);
234
- await elementUpdated(el);
235
- const splitter = el.shadowRoot.querySelector('#splitter');
236
- splitter.setPointerCapture = (id) => (pointerId = id);
237
- splitter.releasePointerCapture = (id) => (pointerId = id);
238
- splitter.dispatchEvent(new PointerEvent('pointerdown', { pointerId: 1 }));
239
- await elementUpdated(el);
240
- expect(pointerId).to.equal(1);
241
- splitter.dispatchEvent(new PointerEvent('pointermove', {
242
- clientX: -10,
243
- }));
244
- await elementUpdated(el);
245
- expect(el.splitterPos || 0).to.equal(0);
246
- splitter.dispatchEvent(new PointerEvent('pointerup'));
247
- await elementUpdated(el);
248
- expect(splitter.classList.contains('is-collapsed-start')).to.be.true;
249
- expect(getComputedStyle(splitter).cursor).to.equal('e-resize');
250
- });
251
- it('resizes to end pos when pointer moves in horizontal splitview', async () => {
252
- let pointerId = -1;
253
- const splitTotalWidth = 400;
254
- const el = await fixture(html `
255
- <sp-split-view
256
- resizable
257
- primary-min="50"
258
- style=${`height: 200px; width: ${splitTotalWidth}px;`}
259
- >
260
- <div>First panel</div>
261
- <div>Second panel</div>
262
- </sp-split-view>
263
- `);
264
- await elementUpdated(el);
265
- const splitter = el.shadowRoot.querySelector('#splitter');
266
- splitter.setPointerCapture = (id) => (pointerId = id);
267
- splitter.releasePointerCapture = (id) => (pointerId = id);
268
- expect(el.primaryMin).to.equal(50);
269
- expect(el.resizable).to.be.true;
270
- splitter.dispatchEvent(new PointerEvent('pointerdown', { pointerId: 1 }));
271
- await elementUpdated(el);
272
- expect(pointerId).to.equal(1);
273
- splitter.dispatchEvent(new PointerEvent('pointermove', {
274
- clientX: splitTotalWidth + 10,
275
- }));
276
- await elementUpdated(el);
277
- expect(el.splitterPos || 0).to.equal(splitTotalWidth - el.splitterSize);
278
- splitter.dispatchEvent(new PointerEvent('pointerup'));
279
- await elementUpdated(el);
280
- expect(splitter.classList.contains('is-collapsed-end')).to.be.true;
281
- expect(getComputedStyle(splitter).cursor).to.equal('w-resize');
282
- });
283
- it('resizes to start pos when pointer moves in [vertical] splitview', async () => {
284
- let pointerId = -1;
285
- const el = await fixture(html `
286
- <sp-split-view
287
- vertical
288
- resizable
289
- primary-min="0"
290
- secondary-min="50"
291
- style="height: 400px; width: 200px;"
292
- >
293
- <div>First panel</div>
294
- <div>Second panel</div>
295
- </sp-split-view>
296
- `);
297
- await elementUpdated(el);
298
- const splitter = el.shadowRoot.querySelector('#splitter');
299
- splitter.setPointerCapture = (id) => (pointerId = id);
300
- splitter.releasePointerCapture = (id) => (pointerId = id);
301
- splitter.dispatchEvent(new PointerEvent('pointerdown', { pointerId: 1 }));
302
- await elementUpdated(el);
303
- expect(pointerId).to.equal(1);
304
- splitter.dispatchEvent(new PointerEvent('pointermove', {
305
- clientY: 0,
306
- }));
307
- await elementUpdated(el);
308
- expect(el.splitterPos || 0).to.equal(0);
309
- splitter.dispatchEvent(new PointerEvent('pointerup'));
310
- await elementUpdated(el);
311
- expect(splitter.classList.contains('is-collapsed-start')).to.be.true;
312
- expect(getComputedStyle(splitter).cursor).to.equal('s-resize');
313
- });
314
- it('resizes to end pos when pointer moves in [vertical] splitview', async () => {
315
- let pointerId = -1;
316
- const splitTotalHeight = 400;
317
- const el = await fixture(html `
318
- <sp-split-view
319
- vertical
320
- resizable
321
- primary-min="50"
322
- style=${`height: ${splitTotalHeight}px; width: 200px;`}
323
- >
324
- <div>First panel</div>
325
- <div>Second panel</div>
326
- </sp-split-view>
327
- `);
328
- await elementUpdated(el);
329
- const splitter = el.shadowRoot.querySelector('#splitter');
330
- splitter.setPointerCapture = (id) => (pointerId = id);
331
- splitter.releasePointerCapture = (id) => (pointerId = id);
332
- expect(el.primaryMin).to.equal(50);
333
- expect(el.resizable).to.be.true;
334
- splitter.dispatchEvent(new PointerEvent('pointerdown', { pointerId: 1 }));
335
- await elementUpdated(el);
336
- expect(pointerId).to.equal(1);
337
- splitter.dispatchEvent(new PointerEvent('pointermove', {
338
- clientY: splitTotalHeight + 10,
339
- }));
340
- await elementUpdated(el);
341
- expect(el.splitterPos || 0).to.equal(splitTotalHeight - el.splitterSize);
342
- splitter.dispatchEvent(new PointerEvent('pointerup'));
343
- await elementUpdated(el);
344
- expect(splitter.classList.contains('is-collapsed-end')).to.be.true;
345
- expect(getComputedStyle(splitter).cursor).to.equal('n-resize');
346
- });
347
- it('resizes and collapses when pointer moves in horizontal splitview', async () => {
348
- let pointerId = -1;
349
- const el = await fixture(html `
350
- <sp-split-view
351
- resizable
352
- collapsible
353
- primary-min="50"
354
- secondary-min="50"
355
- style="height: 200px; width: 400px;"
356
- >
357
- <div>First panel</div>
358
- <div>Second panel</div>
359
- </sp-split-view>
360
- `);
361
- await elementUpdated(el);
362
- expect(el.collapsible).to.be.true;
363
- const splitter = el.shadowRoot.querySelector('#splitter');
364
- splitter.setPointerCapture = (id) => (pointerId = id);
365
- splitter.releasePointerCapture = (id) => (pointerId = id);
366
- splitter.dispatchEvent(new PointerEvent('pointerdown', { pointerId: 1 }));
367
- await elementUpdated(el);
368
- expect(pointerId).to.equal(1);
369
- splitter.dispatchEvent(new PointerEvent('pointermove', {
370
- clientX: 40,
371
- }));
372
- await elementUpdated(el);
373
- expect(el.splitterPos || 0).to.equal(50);
374
- expect(splitter.classList.contains('is-collapsed-start')).to.be.false;
375
- expect(getComputedStyle(splitter).cursor).to.equal('ew-resize');
376
- splitter.dispatchEvent(new PointerEvent('pointermove', {
377
- clientX: -10,
378
- }));
379
- await elementUpdated(el);
380
- expect(el.splitterPos || 0).to.equal(0);
381
- expect(splitter.classList.contains('is-collapsed-start')).to.be.true;
382
- expect(getComputedStyle(splitter).cursor).to.equal('e-resize');
383
- splitter.dispatchEvent(new PointerEvent('pointermove', {
384
- clientX: el.getBoundingClientRect().right - 10,
385
- }));
386
- await elementUpdated(el);
387
- expect(el.splitterPos || 0).to.equal(350);
388
- expect(splitter.classList.contains('is-collapsed-end')).to.be.false;
389
- expect(getComputedStyle(splitter).cursor).to.equal('ew-resize');
390
- splitter.dispatchEvent(new PointerEvent('pointermove', {
391
- clientX: el.getBoundingClientRect().right,
392
- }));
393
- await elementUpdated(el);
394
- expect(el.splitterPos || 0).to.equal(400 - el.splitterSize);
395
- splitter.dispatchEvent(new PointerEvent('pointerup'));
396
- await elementUpdated(el);
397
- expect(splitter.classList.contains('is-collapsed-end')).to.be.true;
398
- expect(getComputedStyle(splitter).cursor).to.equal('w-resize');
399
- });
400
- it('resizes and collapses when pointer moves in [vertical] splitview', async () => {
401
- let pointerId = -1;
402
- const splitTotalHeight = 400;
403
- const el = await fixture(html `
404
- <sp-split-view
405
- vertical
406
- resizable
407
- collapsible
408
- primary-min="50"
409
- secondary-min="50"
410
- style=${`height: ${splitTotalHeight}px; width: 200px;`}
411
- >
412
- <div>First panel</div>
413
- <div>Second panel</div>
414
- </sp-split-view>
415
- `);
416
- await elementUpdated(el);
417
- const splitter = el.shadowRoot.querySelector('#splitter');
418
- splitter.setPointerCapture = (id) => (pointerId = id);
419
- splitter.releasePointerCapture = (id) => (pointerId = id);
420
- splitter.dispatchEvent(new PointerEvent('pointerdown', { pointerId: 1 }));
421
- await elementUpdated(el);
422
- expect(pointerId).to.equal(1);
423
- splitter.dispatchEvent(new PointerEvent('pointermove', {
424
- clientY: 40,
425
- }));
426
- await elementUpdated(el);
427
- expect(el.splitterPos || 0).to.equal(50);
428
- expect(splitter.classList.contains('is-collapsed-start')).to.be.false;
429
- expect(getComputedStyle(splitter).cursor).to.equal('ns-resize');
430
- splitter.dispatchEvent(new PointerEvent('pointermove', {
431
- clientY: -10,
432
- }));
433
- await elementUpdated(el);
434
- expect(el.splitterPos || 0).to.equal(0);
435
- expect(splitter.classList.contains('is-collapsed-start')).to.be.true;
436
- expect(getComputedStyle(splitter).cursor).to.equal('s-resize');
437
- splitter.dispatchEvent(new PointerEvent('pointermove', {
438
- clientY: splitTotalHeight - 40,
439
- }));
440
- await elementUpdated(el);
441
- expect(el.splitterPos || 0).to.equal(splitTotalHeight - 50);
442
- expect(splitter.classList.contains('is-collapsed-end')).to.be.false;
443
- expect(getComputedStyle(splitter).cursor).to.equal('ns-resize');
444
- splitter.dispatchEvent(new PointerEvent('pointermove', {
445
- clientY: splitTotalHeight + 50,
446
- }));
447
- await elementUpdated(el);
448
- expect(el.splitterPos || 0).to.equal(splitTotalHeight - el.splitterSize);
449
- splitter.dispatchEvent(new PointerEvent('pointerup'));
450
- await elementUpdated(el);
451
- expect(splitter.classList.contains('is-collapsed-end')).to.be.true;
452
- expect(getComputedStyle(splitter).cursor).to.equal('n-resize');
453
- });
454
- it('handles focus and keyboard inputs and resizes accordingly for horizontal splitviews [ltr]', async () => {
455
- const splitTotalWidth = 500;
456
- const el = await fixture(html `
457
- <sp-split-view
458
- resizable
459
- primary-min="50"
460
- secondary-min="50"
461
- style=${`height: 200px; width: ${splitTotalWidth}px;`}
462
- >
463
- <div>First panel</div>
464
- <div>Second panel</div>
465
- </sp-split-view>
466
- `);
467
- await elementUpdated(el);
468
- expect(el.resizable).to.be.true;
469
- const pos = el.splitterPos || 0;
470
- const splitter = el.shadowRoot.querySelector('#splitter');
471
- splitter.dispatchEvent(arrowLeftEvent());
472
- await elementUpdated(el);
473
- expect(el.splitterPos || 0).to.equal(pos - 10);
474
- splitter.dispatchEvent(arrowRightEvent());
475
- await elementUpdated(el);
476
- expect(el.splitterPos || 0).to.equal(pos);
477
- splitter.dispatchEvent(arrowUpEvent());
478
- await elementUpdated(el);
479
- expect(el.splitterPos || 0).to.equal(pos + 10);
480
- splitter.dispatchEvent(arrowDownEvent());
481
- await elementUpdated(el);
482
- expect(el.splitterPos || 0).to.equal(pos);
483
- splitter.dispatchEvent(pageUpEvent());
484
- await elementUpdated(el);
485
- expect(el.splitterPos || 0).to.equal(pos + 50);
486
- splitter.dispatchEvent(pageDownEvent());
487
- await elementUpdated(el);
488
- expect(el.splitterPos || 0).to.equal(pos);
489
- splitter.dispatchEvent(homeEvent());
490
- await elementUpdated(el);
491
- expect(el.splitterPos || 0).to.equal(50);
492
- splitter.dispatchEvent(arrowLeftEvent());
493
- await elementUpdated(el);
494
- expect(el.splitterPos || 0).to.equal(50);
495
- splitter.dispatchEvent(endEvent());
496
- await elementUpdated(el);
497
- expect(el.splitterPos || 0).to.equal(splitTotalWidth - 50);
498
- splitter.dispatchEvent(arrowRightEvent());
499
- await elementUpdated(el);
500
- expect(el.splitterPos || 0).to.equal(splitTotalWidth - 50);
501
- splitter.dispatchEvent(shiftTabEvent());
502
- await elementUpdated(el);
503
- const outsideFocused = document.activeElement;
504
- expect(typeof outsideFocused).not.to.equal(splitter);
505
- });
506
- it('handles focus and keyboard inputs and resizes accordingly for horizontal splitviews [rtl]', async () => {
507
- const splitTotalWidth = 500;
508
- const el = await fixture(html `
509
- <sp-split-view
510
- resizable
511
- style=${`height: 200px; width: ${splitTotalWidth}px;`}
512
- dir="rtl"
513
- >
514
- <div>First panel</div>
515
- <div>Second panel</div>
516
- </sp-split-view>
517
- `);
518
- await elementUpdated(el);
519
- expect(el.resizable).to.be.true;
520
- const pos = el.splitterPos || 0;
521
- const splitter = el.shadowRoot.querySelector('#splitter');
522
- splitter.dispatchEvent(arrowLeftEvent());
523
- await elementUpdated(el);
524
- expect(el.splitterPos || 0).to.equal(pos + 10);
525
- splitter.dispatchEvent(arrowRightEvent());
526
- await elementUpdated(el);
527
- expect(el.splitterPos || 0).to.equal(pos);
528
- splitter.dispatchEvent(arrowUpEvent());
529
- await elementUpdated(el);
530
- expect(el.splitterPos || 0).to.equal(pos + 10);
531
- splitter.dispatchEvent(arrowDownEvent());
532
- await elementUpdated(el);
533
- expect(el.splitterPos || 0).to.equal(pos);
534
- splitter.dispatchEvent(pageUpEvent());
535
- await elementUpdated(el);
536
- expect(el.splitterPos || 0).to.equal(pos + 50);
537
- splitter.dispatchEvent(pageDownEvent());
538
- await elementUpdated(el);
539
- expect(el.splitterPos || 0).to.equal(pos);
540
- splitter.dispatchEvent(homeEvent());
541
- await elementUpdated(el);
542
- expect(el.splitterPos || 0).to.equal(0);
543
- splitter.dispatchEvent(endEvent());
544
- await elementUpdated(el);
545
- expect(el.splitterPos || 0).to.equal(splitTotalWidth - el.splitterSize);
546
- splitter.dispatchEvent(shiftTabEvent());
547
- await elementUpdated(el);
548
- const outsideFocused = document.activeElement;
549
- expect(typeof outsideFocused).not.to.equal(splitter);
550
- });
551
- it('handles keyboard inputs and resizes accordingly for [vertical] splitviews', async () => {
552
- const splitTotalHeight = 500;
553
- const el = await fixture(html `
554
- <sp-split-view
555
- vertical
556
- resizable
557
- style=${`width: 200px; height: ${splitTotalHeight}px;`}
558
- >
559
- <div>First panel</div>
560
- <div>Second panel</div>
561
- </sp-split-view>
562
- `);
563
- await elementUpdated(el);
564
- expect(el.resizable).to.be.true;
565
- const pos = el.splitterPos || 0;
566
- const splitter = el.shadowRoot.querySelector('#splitter');
567
- splitter.dispatchEvent(arrowLeftEvent());
568
- await elementUpdated(el);
569
- expect(el.splitterPos || 0).to.equal(pos - 10);
570
- splitter.dispatchEvent(arrowRightEvent());
571
- await elementUpdated(el);
572
- expect(el.splitterPos || 0).to.equal(pos);
573
- splitter.dispatchEvent(arrowUpEvent());
574
- await elementUpdated(el);
575
- expect(el.splitterPos || 0).to.equal(pos - 10);
576
- splitter.dispatchEvent(arrowDownEvent());
577
- await elementUpdated(el);
578
- expect(el.splitterPos || 0).to.equal(pos);
579
- splitter.dispatchEvent(pageUpEvent());
580
- await elementUpdated(el);
581
- expect(el.splitterPos || 0).to.equal(pos - 50);
582
- splitter.dispatchEvent(pageDownEvent());
583
- await elementUpdated(el);
584
- expect(el.splitterPos || 0).to.equal(pos);
585
- splitter.dispatchEvent(homeEvent());
586
- await elementUpdated(el);
587
- expect(el.splitterPos || 0).to.equal(0);
588
- splitter.dispatchEvent(endEvent());
589
- await elementUpdated(el);
590
- expect(el.splitterPos || 0).to.equal(splitTotalHeight - el.splitterSize);
591
- splitter.dispatchEvent(shiftTabEvent());
592
- await elementUpdated(el);
593
- const outsideFocused = document.activeElement;
594
- expect(typeof outsideFocused).not.to.equal(splitter);
595
- });
596
- it('handles focus and keyboard inputs and resizes accordingly for collapsible horizontal splitviews', async () => {
597
- const splitTotalWidth = 500;
598
- const el = await fixture(html `
599
- <sp-split-view
600
- resizable
601
- collapsible
602
- primary-min="50"
603
- secondary-min="50"
604
- style=${`height: 200px; width: ${splitTotalWidth}px;`}
605
- >
606
- <div>First panel</div>
607
- <div>Second panel</div>
608
- </sp-split-view>
609
- `);
610
- await elementUpdated(el);
611
- expect(el.resizable).to.be.true;
612
- const splitter = el.shadowRoot.querySelector('#splitter');
613
- splitter.dispatchEvent(homeEvent());
614
- await elementUpdated(el);
615
- expect(el.splitterPos || 0).to.equal(0);
616
- splitter.dispatchEvent(endEvent());
617
- await elementUpdated(el);
618
- expect(el.splitterPos || 0).to.equal(splitTotalWidth - el.splitterSize);
619
- });
620
- it('does not resize when not resizable', async () => {
621
- const el = await fixture(html `
622
- <sp-split-view>
623
- <div>First panel</div>
624
- <div>Second panel</div>
625
- </sp-split-view>
626
- `);
627
- await elementUpdated(el);
628
- expect(el.resizable).to.be.false;
629
- const pos = el.splitterPos || 0;
630
- const splitter = el.shadowRoot
631
- ? el.shadowRoot.querySelector('#splitter')
632
- : el;
633
- splitter.dispatchEvent(new PointerEvent('pointerdown'));
634
- await elementUpdated(el);
635
- //Send keyboard events to resize
636
- splitter.dispatchEvent(arrowLeftEvent());
637
- await elementUpdated(el);
638
- expect(el.splitterPos || 0).to.equal(pos);
639
- });
640
- it('renders no splitter if only one panel is provided', async () => {
641
- const el = await fixture(html `
642
- <sp-split-view style="width: 400px">
643
- <div id="primary" style="width: 200px">First panel</div>
644
- </sp-split-view>
645
- `);
646
- await elementUpdated(el);
647
- expect(el.resizable).to.be.false;
648
- const splitter = el.shadowRoot.querySelector('#splitter');
649
- expect(splitter).to.be.null;
650
- const slot = el.shadowRoot.querySelector('slot');
651
- expect(slot).to.exist;
652
- expect(slot.assignedElements().length).to.equal(1);
653
- const elPrim = slot.assignedElements()[0];
654
- expect(getComputedStyle(elPrim).width).to.equal('200px');
655
- });
656
- it('renders only 2 out of 3 panels', async () => {
657
- const el = await fixture(html `
658
- <sp-split-view>
659
- <div>First panel</div>
660
- <div>Second panel</div>
661
- <div id="testPanel">Third (invisible) panel</div>
662
- </sp-split-view>
663
- `);
664
- await elementUpdated(el);
665
- const testPanel = el.shadowRoot.querySelector('#testPanel');
666
- expect(testPanel).to.be.null;
667
- });
668
- it('keeps the splitter pos when removing and re-adding a panel', async () => {
669
- var _a, _b;
670
- let pointerId = -1;
671
- const el = await fixture(html `
672
- <sp-split-view resizable style="width: 400px">
673
- <div id="primary">First panel</div>
674
- <div id="secondary">Second panel</div>
675
- </sp-split-view>
676
- `);
677
- await elementUpdated(el);
678
- expect(el.resizable).to.be.true;
679
- let splitter = el.shadowRoot.querySelector('#splitter');
680
- splitter.setPointerCapture = (id) => (pointerId = id);
681
- splitter.releasePointerCapture = (id) => (pointerId = id);
682
- let pos = el.splitterPos || 0;
683
- expect(pos).to.equal(200);
684
- splitter.dispatchEvent(new PointerEvent('pointerdown', { pointerId: 1 }));
685
- await elementUpdated(el);
686
- expect(pointerId).to.equal(1);
687
- pos -= 10;
688
- splitter.dispatchEvent(new PointerEvent('pointermove', {
689
- clientX: pos,
690
- }));
691
- await elementUpdated(el);
692
- expect(Math.round(el.splitterPos || 0)).to.equal(pos - el.getBoundingClientRect().left);
693
- // Remove second panel
694
- const secPanel = (_a = el.lastElementChild) === null || _a === void 0 ? void 0 : _a.cloneNode(true);
695
- expect(secPanel).not.to.be.null;
696
- (_b = el.lastElementChild) === null || _b === void 0 ? void 0 : _b.remove();
697
- await elementUpdated(el);
698
- let slot = el.shadowRoot.querySelector('slot');
699
- expect(slot).to.exist;
700
- expect(slot.assignedElements().length).to.equal(1);
701
- splitter = el.shadowRoot.querySelector('#splitter');
702
- expect(splitter).to.be.null;
703
- if (secPanel) {
704
- // Re-add second panel
705
- el.appendChild(secPanel);
706
- await elementUpdated(el);
707
- expect(Math.round(el.splitterPos || 0)).to.equal(pos - el.getBoundingClientRect().left);
708
- slot = el.shadowRoot.querySelector('slot');
709
- expect(slot).to.exist;
710
- expect(slot.assignedElements().length).to.equal(2);
711
- splitter = el.shadowRoot.querySelector('#splitter');
712
- await expect(splitter).to.be.accessible();
713
- }
714
- });
715
- it('announces when splitterPos moves', async () => {
716
- const changeSpy = spy();
717
- const el = await fixture(html `
718
- <sp-split-view
719
- resizable
720
- style=${`height: 200px; width: 500px;`}
721
- >
722
- <div>First panel</div>
723
- <div>Second panel</div>
724
- </sp-split-view>
725
- `);
726
- el.addEventListener('change', changeSpy);
727
- await elementUpdated(el);
728
- expect(el.resizable).to.be.true;
729
- const pos = el.splitterPos || 0;
730
- const splitter = el.shadowRoot.querySelector('#splitter');
731
- splitter.dispatchEvent(arrowLeftEvent());
732
- await elementUpdated(el);
733
- expect(el.splitterPos || 0).to.equal(pos - 10);
734
- expect(changeSpy.callCount).to.equal(1);
735
- });
736
- it('resizes when primarySize changes', async () => {
737
- const el = await fixture(html `
738
- <sp-split-view
739
- resizable
740
- primary-size="100"
741
- style=${`height: 200px; width: 500px;`}
742
- >
743
- <div>First panel</div>
744
- <div>Second panel</div>
745
- </sp-split-view>
746
- `);
747
- await elementUpdated(el);
748
- expect(el.splitterPos || 0).to.equal(100);
749
- el.primarySize = '300';
750
- await elementUpdated(el);
751
- expect(el.splitterPos || 0).to.equal(300);
752
- });
753
- });
754
- //# sourceMappingURL=split-view.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"split-view.test.js","sourceRoot":"","sources":["split-view.test.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;AAEF,OAAO,EAAE,cAAc,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAEzE,OAAO,qBAAqB,CAAC;AAE7B,OAAO,EACH,cAAc,EACd,cAAc,EACd,eAAe,EACf,YAAY,EACZ,QAAQ,EACR,SAAS,EACT,aAAa,EACb,WAAW,EACX,aAAa,GAChB,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAE5B,QAAQ,CAAC,WAAW,EAAE,GAAG,EAAE;IACvB,EAAE,CAAC,kDAAkD,EAAE,KAAK,IAAI,EAAE;QAC9D,MAAM,EAAE,GAAG,MAAM,OAAO,CACpB,IAAI,CAAA;;;;;aAKH,CACJ,CAAC;QAEF,MAAM,cAAc,CAAC,EAAE,CAAC,CAAC;QACzB,MAAM,MAAM,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,UAAU,EAAE,CAAC;QACpC,MAAM,CAAC,EAAE,CAAC,WAAW,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QAC1C,MAAM,CAAC,EAAE,CAAC,SAAS,CAAC,C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C;IAC5C,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,kCAAkC,EAAE,KAAK,IAAI,EAAE;QAC9C,MAAM,EAAE,GAAG,MAAM,OAAO,CACpB,IAAI,CAAA;;;;4BAIY,8BAA8B;;;;;aAK7C,CACJ,CAAC;QACF,MAAM,cAAc,CAAC,EAAE,CAAC,CAAC;QACzB,MAAM,CAAC,EAAE,CAAC,WAAW,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QAC1C,EAAE,CAAC,WAAW,GAAG,KAAK,CAAC;QACvB,MAAM,cAAc,CAAC,EAAE,CAAC,CAAC;QACzB,MAAM,CAAC,EAAE,CAAC,WAAW,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAC9C,CAAC,CAAC,CAAC;AACP,CAAC,CAAC,CAAC","sourcesContent":["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport { elementUpdated, expect, fixture, html } from '@open-wc/testing';\n\nimport '../sp-split-view.js';\nimport { SplitView } from '../';\nimport {\n arrowDownEvent,\n arrowLeftEvent,\n arrowRightEvent,\n arrowUpEvent,\n endEvent,\n homeEvent,\n pageDownEvent,\n pageUpEvent,\n shiftTabEvent,\n} from '../../../test/testing-helpers.js';\nimport { spy } from 'sinon';\n\ndescribe('SplitView', () => {\n it('loads default (horizontal) split-view accessibly', async () => {\n const el = await fixture<SplitView>(\n html`\n <sp-split-view primary-size=\"100\">\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n await expect(el).to.be.accessible();\n expect(el.splitterPos || 0).to.equal(100);\n expect(el.resizable).to.be.false;\n expect(el.collapsible).to.be.false;\n const gripper = el.shadowRoot.querySelector(\n '#gripper'\n ) as HTMLDivElement;\n expect(gripper).to.be.null;\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n expect(getComputedStyle(splitter).cursor).to.equal('auto');\n });\n\n it('loads horizontal [resizable] split-view accessibly', async () => {\n const el = await fixture<SplitView>(\n html`\n <sp-split-view resizable primary-size=\"100px\">\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n await expect(el).to.be.accessible();\n expect(el.splitterPos || 0).to.equal(100);\n\n const gripper = el.shadowRoot.querySelector(\n '#gripper'\n ) as HTMLDivElement;\n await expect(gripper).to.be.accessible();\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n expect(getComputedStyle(splitter).cursor).to.equal('ew-resize');\n });\n\n it('loads [vertical] split-view accessibly', async () => {\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n vertical\n primary-size=\"75%\"\n style=\"height: 400px\"\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n await expect(el).to.be.accessible();\n expect(el.splitterPos || 0).to.equal(300);\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n expect(getComputedStyle(splitter).cursor).to.equal('auto');\n });\n\n it('loads [vertical] [resizable] split-view accessibly', async () => {\n const el = await fixture<SplitView>(\n html`\n <sp-split-view vertical resizable style=\"height: 400px\">\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n await expect(el).to.be.accessible();\n expect(el.splitterPos || 0).to.equal(200);\n\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n expect(getComputedStyle(splitter).cursor).to.equal('ns-resize');\n });\n\n it('set all panel values', async () => {\n const splitTotalWidth = 400;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n primary-min=\"50\"\n primary-max=\"300\"\n secondary-min=\"50\"\n style=${`height: 500px; width: ${splitTotalWidth}px;`}\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n await elementUpdated(el);\n expect(el.resizable).to.be.true;\n expect(el.primaryMin).to.equal(50);\n expect(el.primaryMax).to.equal(300);\n expect(el.secondaryMin).to.equal(50);\n expect(el.secondaryMax).to.equal(3840);\n });\n\n it('use auto height in primary pane', async () => {\n const splitTotalWidth = 400;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n primary-size=\"auto\"\n style=${`height: 500px; width: ${splitTotalWidth}px;`}\n >\n <div>\n First panel Lorem Ipsum is simply dummy text of the\n printing and typesetting industry. Lorem Ipsum has been\n the industry's standard dummy text ever since the 1500s,\n when an unknown printer took a galley of type and\n scrambled it to make a type specimen book. It has\n survived not only five centuries, but also the leap into\n electronic typesetting, remaining essentially unchanged.\n </div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n await elementUpdated(el);\n expect(el.resizable).to.be.true;\n expect(el.primarySize).to.equal('auto');\n expect(el.splitterPos || 0).to.equal(398);\n });\n\n it('resizes when pointer moves and resizable is enabled [ltr]', async () => {\n let pointerId = -1;\n const splitTotalWidth = 400;\n const el = await fixture<\n SplitView & {\n splitterPos: number;\n }\n >(\n html`\n <sp-split-view\n resizable\n primary-min=\"50\"\n secondary-min=\"50\"\n style=${`height: 200px; width: ${splitTotalWidth}px;`}\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n expect(el.resizable).to.be.true;\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n splitter.setPointerCapture = (id: number) => (pointerId = id);\n splitter.releasePointerCapture = (id: number) => (pointerId = id);\n let pos = el.splitterPos;\n expect(el.splitterPos).to.equal(200);\n\n splitter.dispatchEvent(\n new PointerEvent('pointerdown', { pointerId: 1 })\n );\n await elementUpdated(el);\n expect(pointerId).to.equal(1);\n\n pos -= 10;\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: pos,\n })\n );\n await elementUpdated(el);\n expect(Math.round(el.splitterPos)).to.equal(\n pos - el.getBoundingClientRect().left\n );\n\n // don't collapse to start\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: 0,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos).to.equal(el.primaryMin);\n expect(getComputedStyle(splitter).cursor).to.equal('e-resize');\n\n // don't collapse to end\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: splitTotalWidth,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos, '350 first time').to.equal(\n splitTotalWidth - el.secondaryMin\n );\n expect(getComputedStyle(splitter).cursor).to.equal('w-resize');\n\n splitter.dispatchEvent(new PointerEvent('pointerup'));\n await elementUpdated(el);\n // don't change anything when triggering mouseevent with right button click\n splitter.dispatchEvent(\n new MouseEvent('pointerdown', { button: 2, cancelable: true })\n );\n await elementUpdated(el);\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: 0,\n })\n );\n expect(el.splitterPos, '350 second time, because right click').to.equal(\n splitTotalWidth - el.secondaryMin\n );\n });\n\n it('resizes when pointer moves and resizable is enabled [rtl]', async () => {\n let pointerId = -1;\n const splitTotalWidth = 400;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n primary-min=\"50\"\n secondary-min=\"40\"\n style=${`height: 200px; width: ${splitTotalWidth}px;`}\n dir=\"rtl\"\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n expect(el.resizable).to.be.true;\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n splitter.setPointerCapture = (id: number) => (pointerId = id);\n splitter.releasePointerCapture = (id: number) => (pointerId = id);\n\n let pos = el.splitterPos || 0;\n splitter.dispatchEvent(\n new PointerEvent('pointerdown', { pointerId: 1 })\n );\n await elementUpdated(el);\n expect(pointerId).to.equal(1);\n\n pos = el.getBoundingClientRect().right - 100;\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: pos,\n })\n );\n await elementUpdated(el);\n expect(Math.round(el.splitterPos || 0)).to.equal(\n el.getBoundingClientRect().right - pos\n );\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: 0,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(splitTotalWidth - el.secondaryMin);\n expect(getComputedStyle(splitter).cursor).to.equal('e-resize');\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: el.getBoundingClientRect().right,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(el.primaryMin);\n expect(getComputedStyle(splitter).cursor).to.equal('w-resize');\n });\n\n it('resizes to start pos when pointer moves in horizontal splitview', async () => {\n let pointerId = -1;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n secondary-min=\"50\"\n style=\"height: 200px; width: 400px;\"\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n splitter.setPointerCapture = (id: number) => (pointerId = id);\n splitter.releasePointerCapture = (id: number) => (pointerId = id);\n splitter.dispatchEvent(\n new PointerEvent('pointerdown', { pointerId: 1 })\n );\n await elementUpdated(el);\n expect(pointerId).to.equal(1);\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: -10,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(0);\n\n splitter.dispatchEvent(new PointerEvent('pointerup'));\n await elementUpdated(el);\n expect(splitter.classList.contains('is-collapsed-start')).to.be.true;\n expect(getComputedStyle(splitter).cursor).to.equal('e-resize');\n });\n\n it('resizes to end pos when pointer moves in horizontal splitview', async () => {\n let pointerId = -1;\n const splitTotalWidth = 400;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n primary-min=\"50\"\n style=${`height: 200px; width: ${splitTotalWidth}px;`}\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n splitter.setPointerCapture = (id: number) => (pointerId = id);\n splitter.releasePointerCapture = (id: number) => (pointerId = id);\n expect(el.primaryMin).to.equal(50);\n expect(el.resizable).to.be.true;\n\n splitter.dispatchEvent(\n new PointerEvent('pointerdown', { pointerId: 1 })\n );\n await elementUpdated(el);\n expect(pointerId).to.equal(1);\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: splitTotalWidth + 10,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(splitTotalWidth - el.splitterSize);\n\n splitter.dispatchEvent(new PointerEvent('pointerup'));\n await elementUpdated(el);\n expect(splitter.classList.contains('is-collapsed-end')).to.be.true;\n expect(getComputedStyle(splitter).cursor).to.equal('w-resize');\n });\n\n it('resizes to start pos when pointer moves in [vertical] splitview', async () => {\n let pointerId = -1;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n vertical\n resizable\n primary-min=\"0\"\n secondary-min=\"50\"\n style=\"height: 400px; width: 200px;\"\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n splitter.setPointerCapture = (id: number) => (pointerId = id);\n splitter.releasePointerCapture = (id: number) => (pointerId = id);\n splitter.dispatchEvent(\n new PointerEvent('pointerdown', { pointerId: 1 })\n );\n await elementUpdated(el);\n expect(pointerId).to.equal(1);\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientY: 0,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(0);\n\n splitter.dispatchEvent(new PointerEvent('pointerup'));\n await elementUpdated(el);\n expect(splitter.classList.contains('is-collapsed-start')).to.be.true;\n expect(getComputedStyle(splitter).cursor).to.equal('s-resize');\n });\n\n it('resizes to end pos when pointer moves in [vertical] splitview', async () => {\n let pointerId = -1;\n const splitTotalHeight = 400;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n vertical\n resizable\n primary-min=\"50\"\n style=${`height: ${splitTotalHeight}px; width: 200px;`}\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n splitter.setPointerCapture = (id: number) => (pointerId = id);\n splitter.releasePointerCapture = (id: number) => (pointerId = id);\n expect(el.primaryMin).to.equal(50);\n expect(el.resizable).to.be.true;\n\n splitter.dispatchEvent(\n new PointerEvent('pointerdown', { pointerId: 1 })\n );\n await elementUpdated(el);\n expect(pointerId).to.equal(1);\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientY: splitTotalHeight + 10,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(\n splitTotalHeight - el.splitterSize\n );\n\n splitter.dispatchEvent(new PointerEvent('pointerup'));\n await elementUpdated(el);\n expect(splitter.classList.contains('is-collapsed-end')).to.be.true;\n expect(getComputedStyle(splitter).cursor).to.equal('n-resize');\n });\n\n it('resizes and collapses when pointer moves in horizontal splitview', async () => {\n let pointerId = -1;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n collapsible\n primary-min=\"50\"\n secondary-min=\"50\"\n style=\"height: 200px; width: 400px;\"\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n expect(el.collapsible).to.be.true;\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n splitter.setPointerCapture = (id: number) => (pointerId = id);\n splitter.releasePointerCapture = (id: number) => (pointerId = id);\n splitter.dispatchEvent(\n new PointerEvent('pointerdown', { pointerId: 1 })\n );\n await elementUpdated(el);\n expect(pointerId).to.equal(1);\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: 40,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(50);\n expect(splitter.classList.contains('is-collapsed-start')).to.be.false;\n expect(getComputedStyle(splitter).cursor).to.equal('ew-resize');\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: -10,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(0);\n\n expect(splitter.classList.contains('is-collapsed-start')).to.be.true;\n expect(getComputedStyle(splitter).cursor).to.equal('e-resize');\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: el.getBoundingClientRect().right - 10,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(350);\n expect(splitter.classList.contains('is-collapsed-end')).to.be.false;\n expect(getComputedStyle(splitter).cursor).to.equal('ew-resize');\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: el.getBoundingClientRect().right,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(400 - el.splitterSize);\n\n splitter.dispatchEvent(new PointerEvent('pointerup'));\n await elementUpdated(el);\n expect(splitter.classList.contains('is-collapsed-end')).to.be.true;\n expect(getComputedStyle(splitter).cursor).to.equal('w-resize');\n });\n\n it('resizes and collapses when pointer moves in [vertical] splitview', async () => {\n let pointerId = -1;\n const splitTotalHeight = 400;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n vertical\n resizable\n collapsible\n primary-min=\"50\"\n secondary-min=\"50\"\n style=${`height: ${splitTotalHeight}px; width: 200px;`}\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n splitter.setPointerCapture = (id: number) => (pointerId = id);\n splitter.releasePointerCapture = (id: number) => (pointerId = id);\n splitter.dispatchEvent(\n new PointerEvent('pointerdown', { pointerId: 1 })\n );\n await elementUpdated(el);\n expect(pointerId).to.equal(1);\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientY: 40,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(50);\n expect(splitter.classList.contains('is-collapsed-start')).to.be.false;\n expect(getComputedStyle(splitter).cursor).to.equal('ns-resize');\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientY: -10,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(0);\n\n expect(splitter.classList.contains('is-collapsed-start')).to.be.true;\n expect(getComputedStyle(splitter).cursor).to.equal('s-resize');\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientY: splitTotalHeight - 40,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(splitTotalHeight - 50);\n expect(splitter.classList.contains('is-collapsed-end')).to.be.false;\n expect(getComputedStyle(splitter).cursor).to.equal('ns-resize');\n\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientY: splitTotalHeight + 50,\n })\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(\n splitTotalHeight - el.splitterSize\n );\n\n splitter.dispatchEvent(new PointerEvent('pointerup'));\n await elementUpdated(el);\n expect(splitter.classList.contains('is-collapsed-end')).to.be.true;\n expect(getComputedStyle(splitter).cursor).to.equal('n-resize');\n });\n\n it('handles focus and keyboard inputs and resizes accordingly for horizontal splitviews [ltr]', async () => {\n const splitTotalWidth = 500;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n primary-min=\"50\"\n secondary-min=\"50\"\n style=${`height: 200px; width: ${splitTotalWidth}px;`}\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n expect(el.resizable).to.be.true;\n\n const pos = el.splitterPos || 0;\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n\n splitter.dispatchEvent(arrowLeftEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos - 10);\n\n splitter.dispatchEvent(arrowRightEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos);\n\n splitter.dispatchEvent(arrowUpEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos + 10);\n\n splitter.dispatchEvent(arrowDownEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos);\n\n splitter.dispatchEvent(pageUpEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos + 50);\n\n splitter.dispatchEvent(pageDownEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos);\n\n splitter.dispatchEvent(homeEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(50);\n\n splitter.dispatchEvent(arrowLeftEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(50);\n\n splitter.dispatchEvent(endEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(splitTotalWidth - 50);\n\n splitter.dispatchEvent(arrowRightEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(splitTotalWidth - 50);\n\n splitter.dispatchEvent(shiftTabEvent());\n await elementUpdated(el);\n const outsideFocused = document.activeElement as HTMLElement;\n expect(typeof outsideFocused).not.to.equal(splitter);\n });\n\n it('handles focus and keyboard inputs and resizes accordingly for horizontal splitviews [rtl]', async () => {\n const splitTotalWidth = 500;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n style=${`height: 200px; width: ${splitTotalWidth}px;`}\n dir=\"rtl\"\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n expect(el.resizable).to.be.true;\n\n const pos = el.splitterPos || 0;\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n\n splitter.dispatchEvent(arrowLeftEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos + 10);\n\n splitter.dispatchEvent(arrowRightEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos);\n\n splitter.dispatchEvent(arrowUpEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos + 10);\n\n splitter.dispatchEvent(arrowDownEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos);\n\n splitter.dispatchEvent(pageUpEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos + 50);\n\n splitter.dispatchEvent(pageDownEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos);\n\n splitter.dispatchEvent(homeEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(0);\n\n splitter.dispatchEvent(endEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(splitTotalWidth - el.splitterSize);\n\n splitter.dispatchEvent(shiftTabEvent());\n await elementUpdated(el);\n const outsideFocused = document.activeElement as HTMLElement;\n expect(typeof outsideFocused).not.to.equal(splitter);\n });\n\n it('handles keyboard inputs and resizes accordingly for [vertical] splitviews', async () => {\n const splitTotalHeight = 500;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n vertical\n resizable\n style=${`width: 200px; height: ${splitTotalHeight}px;`}\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n await elementUpdated(el);\n expect(el.resizable).to.be.true;\n\n const pos = el.splitterPos || 0;\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n\n splitter.dispatchEvent(arrowLeftEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos - 10);\n\n splitter.dispatchEvent(arrowRightEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos);\n\n splitter.dispatchEvent(arrowUpEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos - 10);\n\n splitter.dispatchEvent(arrowDownEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos);\n\n splitter.dispatchEvent(pageUpEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos - 50);\n\n splitter.dispatchEvent(pageDownEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos);\n\n splitter.dispatchEvent(homeEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(0);\n\n splitter.dispatchEvent(endEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(\n splitTotalHeight - el.splitterSize\n );\n\n splitter.dispatchEvent(shiftTabEvent());\n await elementUpdated(el);\n const outsideFocused = document.activeElement as HTMLElement;\n expect(typeof outsideFocused).not.to.equal(splitter);\n });\n\n it('handles focus and keyboard inputs and resizes accordingly for collapsible horizontal splitviews', async () => {\n const splitTotalWidth = 500;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n collapsible\n primary-min=\"50\"\n secondary-min=\"50\"\n style=${`height: 200px; width: ${splitTotalWidth}px;`}\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n expect(el.resizable).to.be.true;\n\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n\n splitter.dispatchEvent(homeEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(0);\n\n splitter.dispatchEvent(endEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(splitTotalWidth - el.splitterSize);\n });\n\n it('does not resize when not resizable', async () => {\n const el = await fixture<SplitView>(\n html`\n <sp-split-view>\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n await elementUpdated(el);\n expect(el.resizable).to.be.false;\n\n const pos = el.splitterPos || 0;\n const splitter = el.shadowRoot\n ? (el.shadowRoot.querySelector('#splitter') as HTMLDivElement)\n : (el as SplitView);\n splitter.dispatchEvent(new PointerEvent('pointerdown'));\n await elementUpdated(el);\n //Send keyboard events to resize\n splitter.dispatchEvent(arrowLeftEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos);\n });\n\n it('renders no splitter if only one panel is provided', async () => {\n const el = await fixture<SplitView>(\n html`\n <sp-split-view style=\"width: 400px\">\n <div id=\"primary\" style=\"width: 200px\">First panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n expect(el.resizable).to.be.false;\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n expect(splitter).to.be.null;\n\n const slot = el.shadowRoot.querySelector('slot') as HTMLSlotElement;\n expect(slot).to.exist;\n\n expect(slot.assignedElements().length).to.equal(1);\n\n const elPrim = slot.assignedElements()[0] as HTMLDivElement;\n expect(getComputedStyle(elPrim).width).to.equal('200px');\n });\n\n it('renders only 2 out of 3 panels', async () => {\n const el = await fixture<SplitView>(\n html`\n <sp-split-view>\n <div>First panel</div>\n <div>Second panel</div>\n <div id=\"testPanel\">Third (invisible) panel</div>\n </sp-split-view>\n `\n );\n await elementUpdated(el);\n const testPanel = el.shadowRoot.querySelector(\n '#testPanel'\n ) as HTMLDivElement;\n expect(testPanel).to.be.null;\n });\n\n it('keeps the splitter pos when removing and re-adding a panel', async () => {\n let pointerId = -1;\n const el = await fixture<SplitView>(\n html`\n <sp-split-view resizable style=\"width: 400px\">\n <div id=\"primary\">First panel</div>\n <div id=\"secondary\">Second panel</div>\n </sp-split-view>\n `\n );\n\n await elementUpdated(el);\n expect(el.resizable).to.be.true;\n let splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n splitter.setPointerCapture = (id: number) => (pointerId = id);\n splitter.releasePointerCapture = (id: number) => (pointerId = id);\n let pos = el.splitterPos || 0;\n expect(pos).to.equal(200);\n\n splitter.dispatchEvent(\n new PointerEvent('pointerdown', { pointerId: 1 })\n );\n await elementUpdated(el);\n expect(pointerId).to.equal(1);\n\n pos -= 10;\n splitter.dispatchEvent(\n new PointerEvent('pointermove', {\n clientX: pos,\n })\n );\n await elementUpdated(el);\n expect(Math.round(el.splitterPos || 0)).to.equal(\n pos - el.getBoundingClientRect().left\n );\n\n // Remove second panel\n const secPanel = el.lastElementChild?.cloneNode(true);\n expect(secPanel).not.to.be.null;\n\n el.lastElementChild?.remove();\n await elementUpdated(el);\n let slot = el.shadowRoot.querySelector('slot') as HTMLSlotElement;\n expect(slot).to.exist;\n expect(slot.assignedElements().length).to.equal(1);\n\n splitter = el.shadowRoot.querySelector('#splitter') as HTMLDivElement;\n expect(splitter).to.be.null;\n\n if (secPanel) {\n // Re-add second panel\n el.appendChild(secPanel);\n await elementUpdated(el);\n expect(Math.round(el.splitterPos || 0)).to.equal(\n pos - el.getBoundingClientRect().left\n );\n slot = el.shadowRoot.querySelector('slot') as HTMLSlotElement;\n expect(slot).to.exist;\n\n expect(slot.assignedElements().length).to.equal(2);\n\n splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n await expect(splitter).to.be.accessible();\n }\n });\n\n it('announces when splitterPos moves', async () => {\n const changeSpy = spy();\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n style=${`height: 200px; width: 500px;`}\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n el.addEventListener('change', changeSpy);\n await elementUpdated(el);\n expect(el.resizable).to.be.true;\n\n const pos = el.splitterPos || 0;\n const splitter = el.shadowRoot.querySelector(\n '#splitter'\n ) as HTMLDivElement;\n\n splitter.dispatchEvent(arrowLeftEvent());\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(pos - 10);\n expect(changeSpy.callCount).to.equal(1);\n });\n\n it('resizes when primarySize changes', async () => {\n const el = await fixture<SplitView>(\n html`\n <sp-split-view\n resizable\n primary-size=\"100\"\n style=${`height: 200px; width: 500px;`}\n >\n <div>First panel</div>\n <div>Second panel</div>\n </sp-split-view>\n `\n );\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(100);\n el.primarySize = '300';\n await elementUpdated(el);\n expect(el.splitterPos || 0).to.equal(300);\n });\n});\n"]}