@spectrum-web-components/contextual-help 1.6.1-beta.0 → 1.7.0-snapshot.20250519143559
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 +7 -10
- package/custom-elements.json +0 -236
- package/src/spectrum-config.js +0 -54
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spectrum-web-components/contextual-help",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0-snapshot.20250519143559",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -64,15 +64,12 @@
|
|
|
64
64
|
"css"
|
|
65
65
|
],
|
|
66
66
|
"dependencies": {
|
|
67
|
-
"@spectrum-web-components/action-button": "1.
|
|
68
|
-
"@spectrum-web-components/base": "1.
|
|
69
|
-
"@spectrum-web-components/dialog": "1.
|
|
70
|
-
"@spectrum-web-components/icons-workflow": "1.
|
|
71
|
-
"@spectrum-web-components/overlay": "1.
|
|
72
|
-
"@spectrum-web-components/popover": "1.
|
|
73
|
-
},
|
|
74
|
-
"devDependencies": {
|
|
75
|
-
"@spectrum-css/contextualhelp": "5.1.2"
|
|
67
|
+
"@spectrum-web-components/action-button": "1.7.0-snapshot.20250519143559",
|
|
68
|
+
"@spectrum-web-components/base": "1.7.0-snapshot.20250519143559",
|
|
69
|
+
"@spectrum-web-components/dialog": "1.7.0-snapshot.20250519143559",
|
|
70
|
+
"@spectrum-web-components/icons-workflow": "1.7.0-snapshot.20250519143559",
|
|
71
|
+
"@spectrum-web-components/overlay": "1.7.0-snapshot.20250519143559",
|
|
72
|
+
"@spectrum-web-components/popover": "1.7.0-snapshot.20250519143559"
|
|
76
73
|
},
|
|
77
74
|
"types": "./src/index.d.ts",
|
|
78
75
|
"customElements": "custom-elements.json",
|
package/custom-elements.json
DELETED
|
@@ -1,236 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"schemaVersion": "1.0.0",
|
|
3
|
-
"readme": "",
|
|
4
|
-
"modules": [
|
|
5
|
-
{
|
|
6
|
-
"kind": "javascript-module",
|
|
7
|
-
"path": "sp-contextual-help.js",
|
|
8
|
-
"declarations": [],
|
|
9
|
-
"exports": [
|
|
10
|
-
{
|
|
11
|
-
"kind": "custom-element-definition",
|
|
12
|
-
"name": "sp-contextual-help",
|
|
13
|
-
"declaration": {
|
|
14
|
-
"name": "ContextualHelp",
|
|
15
|
-
"module": "/src/ContextualHelp.js"
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
]
|
|
19
|
-
},
|
|
20
|
-
{
|
|
21
|
-
"kind": "javascript-module",
|
|
22
|
-
"path": "src/ContextualHelp.js",
|
|
23
|
-
"declarations": [
|
|
24
|
-
{
|
|
25
|
-
"kind": "class",
|
|
26
|
-
"description": "Spectrum Contextual help provides additional information about\nthe state of either an adjacent component or an entire view.",
|
|
27
|
-
"name": "ContextualHelp",
|
|
28
|
-
"slots": [
|
|
29
|
-
{
|
|
30
|
-
"description": "content to display as the heading of the popover",
|
|
31
|
-
"name": "heading"
|
|
32
|
-
},
|
|
33
|
-
{
|
|
34
|
-
"description": "content to display in the popover",
|
|
35
|
-
"name": "Text"
|
|
36
|
-
},
|
|
37
|
-
{
|
|
38
|
-
"description": "link to additional informations",
|
|
39
|
-
"name": "link"
|
|
40
|
-
}
|
|
41
|
-
],
|
|
42
|
-
"members": [
|
|
43
|
-
{
|
|
44
|
-
"kind": "field",
|
|
45
|
-
"name": "isMobile",
|
|
46
|
-
"privacy": "public",
|
|
47
|
-
"default": "new MatchMediaController(this, IS_MOBILE)"
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
"kind": "field",
|
|
51
|
-
"name": "label",
|
|
52
|
-
"type": {
|
|
53
|
-
"text": "string | undefined"
|
|
54
|
-
},
|
|
55
|
-
"privacy": "public",
|
|
56
|
-
"description": "Provides an accessible name for the action button trigger.",
|
|
57
|
-
"parameters": [
|
|
58
|
-
{
|
|
59
|
-
"name": "label",
|
|
60
|
-
"type": {
|
|
61
|
-
"text": "String"
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
],
|
|
65
|
-
"attribute": "label"
|
|
66
|
-
},
|
|
67
|
-
{
|
|
68
|
-
"kind": "field",
|
|
69
|
-
"name": "variant",
|
|
70
|
-
"type": {
|
|
71
|
-
"text": "'info' | 'help'"
|
|
72
|
-
},
|
|
73
|
-
"privacy": "public",
|
|
74
|
-
"default": "'info'",
|
|
75
|
-
"description": "The `variant` property applies specific styling on the action button trigger.",
|
|
76
|
-
"parameters": [
|
|
77
|
-
{
|
|
78
|
-
"name": "variant",
|
|
79
|
-
"type": {
|
|
80
|
-
"text": "String"
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
],
|
|
84
|
-
"attribute": "variant"
|
|
85
|
-
},
|
|
86
|
-
{
|
|
87
|
-
"kind": "field",
|
|
88
|
-
"name": "placement",
|
|
89
|
-
"type": {
|
|
90
|
-
"text": "\"top\" | \"top-start\" | \"top-end\" | \"right\" | \"right-start\" | \"right-end\" | \"bottom\" | \"bottom-start\" | \"bottom-end\" | \"left\" | \"left-start\" | \"left-end\""
|
|
91
|
-
},
|
|
92
|
-
"privacy": "public",
|
|
93
|
-
"default": "'bottom-start'",
|
|
94
|
-
"attribute": "placement",
|
|
95
|
-
"reflects": true
|
|
96
|
-
},
|
|
97
|
-
{
|
|
98
|
-
"kind": "field",
|
|
99
|
-
"name": "offset",
|
|
100
|
-
"type": {
|
|
101
|
-
"text": "number | [number, number]"
|
|
102
|
-
},
|
|
103
|
-
"privacy": "public",
|
|
104
|
-
"default": "0",
|
|
105
|
-
"description": "The `offset` property accepts either a single number, to\ndefine the offset of the Popover along the main axis from\nthe action button, or 2-tuple, to define the offset along the\nmain axis and the cross axis.",
|
|
106
|
-
"attribute": "offset"
|
|
107
|
-
},
|
|
108
|
-
{
|
|
109
|
-
"kind": "field",
|
|
110
|
-
"name": "open",
|
|
111
|
-
"type": {
|
|
112
|
-
"text": "boolean"
|
|
113
|
-
},
|
|
114
|
-
"default": "false",
|
|
115
|
-
"attribute": "open"
|
|
116
|
-
},
|
|
117
|
-
{
|
|
118
|
-
"kind": "field",
|
|
119
|
-
"name": "buttonAriaLabel",
|
|
120
|
-
"type": {
|
|
121
|
-
"text": "string"
|
|
122
|
-
},
|
|
123
|
-
"privacy": "public",
|
|
124
|
-
"readonly": true
|
|
125
|
-
},
|
|
126
|
-
{
|
|
127
|
-
"kind": "method",
|
|
128
|
-
"name": "renderOverlayContent",
|
|
129
|
-
"privacy": "private",
|
|
130
|
-
"return": {
|
|
131
|
-
"type": {
|
|
132
|
-
"text": "TemplateResult"
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
},
|
|
136
|
-
{
|
|
137
|
-
"kind": "method",
|
|
138
|
-
"name": "handleSlottableRequest",
|
|
139
|
-
"privacy": "private",
|
|
140
|
-
"return": {
|
|
141
|
-
"type": {
|
|
142
|
-
"text": "void"
|
|
143
|
-
}
|
|
144
|
-
},
|
|
145
|
-
"parameters": [
|
|
146
|
-
{
|
|
147
|
-
"name": "event",
|
|
148
|
-
"type": {
|
|
149
|
-
"text": "SlottableRequestEvent"
|
|
150
|
-
}
|
|
151
|
-
}
|
|
152
|
-
]
|
|
153
|
-
}
|
|
154
|
-
],
|
|
155
|
-
"attributes": [
|
|
156
|
-
{
|
|
157
|
-
"name": "placement",
|
|
158
|
-
"type": {
|
|
159
|
-
"text": "\"top\" | \"top-start\" | \"top-end\" | \"right\" | \"right-start\" | \"right-end\" | \"bottom\" | \"bottom-start\" | \"bottom-end\" | \"left\" | \"left-start\" | \"left-end\""
|
|
160
|
-
},
|
|
161
|
-
"default": "'bottom-start'",
|
|
162
|
-
"fieldName": "placement",
|
|
163
|
-
"attribute": "placement"
|
|
164
|
-
},
|
|
165
|
-
{
|
|
166
|
-
"name": "label",
|
|
167
|
-
"type": {
|
|
168
|
-
"text": "string | undefined"
|
|
169
|
-
},
|
|
170
|
-
"description": "Provides an accessible name for the action button trigger.",
|
|
171
|
-
"parameters": [
|
|
172
|
-
{
|
|
173
|
-
"name": "label",
|
|
174
|
-
"type": {
|
|
175
|
-
"text": "String"
|
|
176
|
-
}
|
|
177
|
-
}
|
|
178
|
-
],
|
|
179
|
-
"fieldName": "label"
|
|
180
|
-
},
|
|
181
|
-
{
|
|
182
|
-
"name": "variant",
|
|
183
|
-
"type": {
|
|
184
|
-
"text": "'info' | 'help'"
|
|
185
|
-
},
|
|
186
|
-
"default": "'info'",
|
|
187
|
-
"description": "The `variant` property applies specific styling on the action button trigger.",
|
|
188
|
-
"parameters": [
|
|
189
|
-
{
|
|
190
|
-
"name": "variant",
|
|
191
|
-
"type": {
|
|
192
|
-
"text": "String"
|
|
193
|
-
}
|
|
194
|
-
}
|
|
195
|
-
],
|
|
196
|
-
"fieldName": "variant"
|
|
197
|
-
},
|
|
198
|
-
{
|
|
199
|
-
"name": "offset",
|
|
200
|
-
"type": {
|
|
201
|
-
"text": "number | [number, number]"
|
|
202
|
-
},
|
|
203
|
-
"default": "0",
|
|
204
|
-
"description": "The `offset` property accepts either a single number, to\ndefine the offset of the Popover along the main axis from\nthe action button, or 2-tuple, to define the offset along the\nmain axis and the cross axis.",
|
|
205
|
-
"fieldName": "offset"
|
|
206
|
-
},
|
|
207
|
-
{
|
|
208
|
-
"name": "open",
|
|
209
|
-
"type": {
|
|
210
|
-
"text": "boolean"
|
|
211
|
-
},
|
|
212
|
-
"default": "false",
|
|
213
|
-
"fieldName": "open"
|
|
214
|
-
}
|
|
215
|
-
],
|
|
216
|
-
"superclass": {
|
|
217
|
-
"name": "SpectrumElement",
|
|
218
|
-
"package": "@spectrum-web-components/base"
|
|
219
|
-
},
|
|
220
|
-
"tagName": "sp-contextual-help",
|
|
221
|
-
"customElement": true
|
|
222
|
-
}
|
|
223
|
-
],
|
|
224
|
-
"exports": [
|
|
225
|
-
{
|
|
226
|
-
"kind": "js",
|
|
227
|
-
"name": "ContextualHelp",
|
|
228
|
-
"declaration": {
|
|
229
|
-
"name": "ContextualHelp",
|
|
230
|
-
"module": "src/ContextualHelp.js"
|
|
231
|
-
}
|
|
232
|
-
}
|
|
233
|
-
]
|
|
234
|
-
}
|
|
235
|
-
]
|
|
236
|
-
}
|
package/src/spectrum-config.js
DELETED
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
Copyright 2024 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
|
-
// @ts-check
|
|
13
|
-
|
|
14
|
-
import {
|
|
15
|
-
builder,
|
|
16
|
-
converterFor,
|
|
17
|
-
} from '../../../tasks/process-spectrum-utils.js';
|
|
18
|
-
|
|
19
|
-
const converter = converterFor('spectrum-ContextualHelp');
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* @type { import('../../../tasks/spectrum-css-converter').SpectrumCSSConverter }
|
|
23
|
-
*/
|
|
24
|
-
const config = {
|
|
25
|
-
conversions: [
|
|
26
|
-
{
|
|
27
|
-
inPackage: '@spectrum-css/contextualhelp',
|
|
28
|
-
outPackage: 'contextual-help',
|
|
29
|
-
fileName: 'contextual-help',
|
|
30
|
-
hoistCustomPropertiesFrom: 'spectrum-ContextualHelp',
|
|
31
|
-
excludeByComponents: [
|
|
32
|
-
// No need to style the trigger, it is already styled by sp-button
|
|
33
|
-
builder.class('spectrum-ContextualHelp-button'),
|
|
34
|
-
builder.class('spectrum--large'),
|
|
35
|
-
],
|
|
36
|
-
components: [
|
|
37
|
-
// The min-width should be applied to the popover, not the :host
|
|
38
|
-
converter.classToClass('spectrum-ContextualHelp', 'popover'),
|
|
39
|
-
converter.classToClass('spectrum-ContextualHelp-popover'),
|
|
40
|
-
converter.classToSlotted(
|
|
41
|
-
'spectrum-ContextualHelp-heading',
|
|
42
|
-
'heading'
|
|
43
|
-
),
|
|
44
|
-
converter.classToClass('spectrum-ContextualHelp-body'),
|
|
45
|
-
converter.classToSlotted(
|
|
46
|
-
'spectrum-ContextualHelp-link',
|
|
47
|
-
'link'
|
|
48
|
-
),
|
|
49
|
-
],
|
|
50
|
-
},
|
|
51
|
-
],
|
|
52
|
-
};
|
|
53
|
-
|
|
54
|
-
export default config;
|