@rogieking/figui3 8.9.43 → 8.9.44
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/components.css +20 -10
- package/dist/components.css +1 -1
- package/dist/fig-lab.css +1 -1
- package/dist/fig-lab.js +1 -1
- package/dist/fig.css +1 -1
- package/dist/fig.js +1 -1
- package/fig-lab.css +20 -10
- package/fig-lab.js +7 -7
- package/fig.js +5 -4
- package/package.json +1 -1
package/fig-lab.css
CHANGED
|
@@ -250,6 +250,7 @@ propskit-group {
|
|
|
250
250
|
& > fig-header {
|
|
251
251
|
cursor: default;
|
|
252
252
|
padding-left: var(--spacer-3);
|
|
253
|
+
gap: 0;
|
|
253
254
|
|
|
254
255
|
&:focus-visible {
|
|
255
256
|
--figma-focus-outline-radius: var(--radius-medium);
|
|
@@ -258,19 +259,28 @@ propskit-group {
|
|
|
258
259
|
border-radius: var(--figma-focus-outline-radius);
|
|
259
260
|
}
|
|
260
261
|
|
|
261
|
-
h3 {
|
|
262
|
+
& > h3 {
|
|
263
|
+
flex: 1 1 auto;
|
|
264
|
+
min-width: 0;
|
|
265
|
+
display: block;
|
|
262
266
|
margin: 0;
|
|
267
|
+
padding-left: 0;
|
|
268
|
+
text-overflow: ellipsis;
|
|
269
|
+
overflow: hidden;
|
|
270
|
+
white-space: nowrap;
|
|
271
|
+
max-width: 100%;
|
|
263
272
|
user-select: none;
|
|
273
|
+
}
|
|
264
274
|
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
275
|
+
& > .propskit-group-chevron {
|
|
276
|
+
--icon: var(--icon-16-chevron);
|
|
277
|
+
--size: 1rem;
|
|
278
|
+
flex: 0 0 auto;
|
|
279
|
+
color: var(--figma-color-text-tertiary);
|
|
280
|
+
transform: rotate(-90deg);
|
|
281
|
+
transition: transform var(--transition-duration)
|
|
282
|
+
var(--transition-timing-function);
|
|
283
|
+
margin-left: calc(var(--spacer-2) * -1);
|
|
274
284
|
}
|
|
275
285
|
}
|
|
276
286
|
|
package/fig-lab.js
CHANGED
|
@@ -4589,10 +4589,7 @@ class PropskitGroup extends HTMLElement {
|
|
|
4589
4589
|
|
|
4590
4590
|
if (!h3.id) h3.id = figLabUniqueId("propskit-group");
|
|
4591
4591
|
if (this.#header.dataset.generated) {
|
|
4592
|
-
// Preserve chevron while updating the title text node.
|
|
4593
|
-
const chevron = h3.querySelector(".propskit-group-chevron");
|
|
4594
4592
|
h3.textContent = label;
|
|
4595
|
-
if (chevron) h3.prepend(chevron);
|
|
4596
4593
|
}
|
|
4597
4594
|
if (!this.hasAttribute("role")) this.setAttribute("role", "group");
|
|
4598
4595
|
if (
|
|
@@ -4602,14 +4599,17 @@ class PropskitGroup extends HTMLElement {
|
|
|
4602
4599
|
this.setAttribute("aria-labelledby", h3.id);
|
|
4603
4600
|
}
|
|
4604
4601
|
|
|
4605
|
-
|
|
4606
|
-
|
|
4602
|
+
let chevron =
|
|
4603
|
+
this.#header.querySelector(":scope > .propskit-group-chevron") ||
|
|
4604
|
+
h3.querySelector(":scope > .propskit-group-chevron");
|
|
4605
|
+
if (!chevron) {
|
|
4606
|
+
chevron = document.createElement("fig-icon");
|
|
4607
4607
|
chevron.setAttribute("name", "chevron");
|
|
4608
4608
|
chevron.setAttribute("size", "small");
|
|
4609
4609
|
chevron.className = "propskit-group-chevron";
|
|
4610
|
-
h3.prepend(chevron);
|
|
4611
4610
|
}
|
|
4612
|
-
this.#chevron
|
|
4611
|
+
this.#header.insertBefore(chevron, h3);
|
|
4612
|
+
this.#chevron = chevron;
|
|
4613
4613
|
this.#syncResetButton();
|
|
4614
4614
|
this.#header.setAttribute("role", "button");
|
|
4615
4615
|
this.#syncDisabled();
|
package/fig.js
CHANGED
|
@@ -16987,14 +16987,15 @@ class FigGroup extends HTMLElement {
|
|
|
16987
16987
|
}
|
|
16988
16988
|
|
|
16989
16989
|
if (isCollapsible) {
|
|
16990
|
-
|
|
16991
|
-
|
|
16990
|
+
let chevron = this.#header.querySelector(".fig-group-chevron");
|
|
16991
|
+
if (!chevron) {
|
|
16992
|
+
chevron = createFigIcon("chevron", {
|
|
16992
16993
|
size: "small",
|
|
16993
16994
|
className: "fig-group-chevron",
|
|
16994
16995
|
});
|
|
16995
|
-
h3.prepend(chevron);
|
|
16996
16996
|
}
|
|
16997
|
-
this.#chevron
|
|
16997
|
+
this.#header.insertBefore(chevron, h3);
|
|
16998
|
+
this.#chevron = chevron;
|
|
16998
16999
|
h3.removeEventListener("click", this.#handleToggle);
|
|
16999
17000
|
this.#header.removeEventListener("click", this.#handleToggle);
|
|
17000
17001
|
this.#header.addEventListener("click", this.#handleToggle);
|
package/package.json
CHANGED