@frontify/fondue-components 23.0.0-rc.1 → 23.0.0
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/dist/fondue-components.js +46 -50
- package/dist/fondue-components.js.map +1 -1
- package/dist/fondue-components10.js +27 -24
- package/dist/fondue-components10.js.map +1 -1
- package/dist/fondue-components11.js +86 -104
- package/dist/fondue-components11.js.map +1 -1
- package/dist/fondue-components12.js +2 -2
- package/dist/fondue-components13.js +82 -79
- package/dist/fondue-components13.js.map +1 -1
- package/dist/fondue-components14.js +2 -2
- package/dist/fondue-components15.js +2 -2
- package/dist/fondue-components16.js +2 -2
- package/dist/fondue-components17.js +36 -56
- package/dist/fondue-components17.js.map +1 -1
- package/dist/fondue-components18.js +16 -34
- package/dist/fondue-components18.js.map +1 -1
- package/dist/fondue-components19.js +73 -18
- package/dist/fondue-components19.js.map +1 -1
- package/dist/fondue-components20.js +36 -18
- package/dist/fondue-components20.js.map +1 -1
- package/dist/fondue-components21.js +50 -71
- package/dist/fondue-components21.js.map +1 -1
- package/dist/fondue-components22.js +138 -36
- package/dist/fondue-components22.js.map +1 -1
- package/dist/fondue-components23.js +50 -50
- package/dist/fondue-components23.js.map +1 -1
- package/dist/fondue-components24.js +33 -138
- package/dist/fondue-components24.js.map +1 -1
- package/dist/fondue-components25.js +193 -52
- package/dist/fondue-components25.js.map +1 -1
- package/dist/fondue-components26.js +137 -29
- package/dist/fondue-components26.js.map +1 -1
- package/dist/fondue-components27.js +127 -170
- package/dist/fondue-components27.js.map +1 -1
- package/dist/fondue-components28.js +30 -134
- package/dist/fondue-components28.js.map +1 -1
- package/dist/fondue-components29.js +63 -130
- package/dist/fondue-components29.js.map +1 -1
- package/dist/fondue-components3.js +1 -1
- package/dist/fondue-components30.js +101 -31
- package/dist/fondue-components30.js.map +1 -1
- package/dist/fondue-components31.js +29 -63
- package/dist/fondue-components31.js.map +1 -1
- package/dist/fondue-components32.js +52 -98
- package/dist/fondue-components32.js.map +1 -1
- package/dist/fondue-components33.js +20 -12
- package/dist/fondue-components33.js.map +1 -1
- package/dist/fondue-components34.js +23 -56
- package/dist/fondue-components34.js.map +1 -1
- package/dist/fondue-components35.js +7 -20
- package/dist/fondue-components35.js.map +1 -1
- package/dist/fondue-components36.js +6 -7
- package/dist/fondue-components36.js.map +1 -1
- package/dist/fondue-components37.js +32 -7
- package/dist/fondue-components37.js.map +1 -1
- package/dist/fondue-components38.js +5 -32
- package/dist/fondue-components38.js.map +1 -1
- package/dist/fondue-components39.js +12 -5
- package/dist/fondue-components39.js.map +1 -1
- package/dist/fondue-components4.js +35 -31
- package/dist/fondue-components4.js.map +1 -1
- package/dist/fondue-components40.js +153 -18
- package/dist/fondue-components40.js.map +1 -1
- package/dist/fondue-components41.js +22 -59
- package/dist/fondue-components41.js.map +1 -1
- package/dist/fondue-components42.js +19 -19
- package/dist/fondue-components42.js.map +1 -1
- package/dist/fondue-components43.js +15 -112
- package/dist/fondue-components43.js.map +1 -1
- package/dist/fondue-components44.js +30 -19
- package/dist/fondue-components44.js.map +1 -1
- package/dist/fondue-components45.js +54 -32
- package/dist/fondue-components45.js.map +1 -1
- package/dist/fondue-components46.js +125 -47
- package/dist/fondue-components46.js.map +1 -1
- package/dist/fondue-components47.js +20 -129
- package/dist/fondue-components47.js.map +1 -1
- package/dist/fondue-components48.js +53 -21
- package/dist/fondue-components48.js.map +1 -1
- package/dist/fondue-components49.js +8 -53
- package/dist/fondue-components49.js.map +1 -1
- package/dist/fondue-components5.js +2 -2
- package/dist/fondue-components50.js +13 -8
- package/dist/fondue-components50.js.map +1 -1
- package/dist/fondue-components51.js +15 -13
- package/dist/fondue-components51.js.map +1 -1
- package/dist/fondue-components52.js +4 -14
- package/dist/fondue-components52.js.map +1 -1
- package/dist/fondue-components53.js +60 -5
- package/dist/fondue-components53.js.map +1 -1
- package/dist/fondue-components54.js +17 -58
- package/dist/fondue-components54.js.map +1 -1
- package/dist/fondue-components55.js +19 -18
- package/dist/fondue-components55.js.map +1 -1
- package/dist/fondue-components56.js +4 -18
- package/dist/fondue-components56.js.map +1 -1
- package/dist/fondue-components57.js +13 -3
- package/dist/fondue-components57.js.map +1 -1
- package/dist/fondue-components58.js +3 -11
- package/dist/fondue-components58.js.map +1 -1
- package/dist/fondue-components59.js +17 -3
- package/dist/fondue-components59.js.map +1 -1
- package/dist/fondue-components6.js +4 -4
- package/dist/fondue-components60.js +10 -17
- package/dist/fondue-components60.js.map +1 -1
- package/dist/fondue-components61.js +35 -11
- package/dist/fondue-components61.js.map +1 -1
- package/dist/fondue-components62.js +4 -36
- package/dist/fondue-components62.js.map +1 -1
- package/dist/fondue-components63.js +13 -35
- package/dist/fondue-components63.js.map +1 -1
- package/dist/fondue-components64.js +1 -1
- package/dist/fondue-components65.js +24 -12
- package/dist/fondue-components65.js.map +1 -1
- package/dist/fondue-components66.js +16 -4
- package/dist/fondue-components66.js.map +1 -1
- package/dist/fondue-components67.js +150 -23
- package/dist/fondue-components67.js.map +1 -1
- package/dist/fondue-components68.js +19 -17
- package/dist/fondue-components68.js.map +1 -1
- package/dist/fondue-components69.js +75 -148
- package/dist/fondue-components69.js.map +1 -1
- package/dist/fondue-components7.js +2 -2
- package/dist/fondue-components70.js +8 -19
- package/dist/fondue-components70.js.map +1 -1
- package/dist/fondue-components71.js +36 -77
- package/dist/fondue-components71.js.map +1 -1
- package/dist/fondue-components72.js +71 -8
- package/dist/fondue-components72.js.map +1 -1
- package/dist/fondue-components73.js +10 -36
- package/dist/fondue-components73.js.map +1 -1
- package/dist/fondue-components74.js +12 -70
- package/dist/fondue-components74.js.map +1 -1
- package/dist/fondue-components75.js +12 -10
- package/dist/fondue-components75.js.map +1 -1
- package/dist/fondue-components76.js +22 -12
- package/dist/fondue-components76.js.map +1 -1
- package/dist/fondue-components77.js +34 -13
- package/dist/fondue-components77.js.map +1 -1
- package/dist/fondue-components78.js +10 -22
- package/dist/fondue-components78.js.map +1 -1
- package/dist/fondue-components79.js +67 -33
- package/dist/fondue-components79.js.map +1 -1
- package/dist/fondue-components8.js +5 -5
- package/dist/fondue-components80.js +11 -7
- package/dist/fondue-components80.js.map +1 -1
- package/dist/fondue-components81.js +25 -67
- package/dist/fondue-components81.js.map +1 -1
- package/dist/fondue-components82.js +18 -14
- package/dist/fondue-components82.js.map +1 -1
- package/dist/fondue-components83.js +21 -23
- package/dist/fondue-components83.js.map +1 -1
- package/dist/fondue-components84.js +6 -18
- package/dist/fondue-components84.js.map +1 -1
- package/dist/fondue-components85.js +19 -22
- package/dist/fondue-components85.js.map +1 -1
- package/dist/fondue-components86.js +6 -8
- package/dist/fondue-components86.js.map +1 -1
- package/dist/fondue-components87.js +3 -5
- package/dist/fondue-components87.js.map +1 -1
- package/dist/fondue-components88.js +5 -2
- package/dist/fondue-components88.js.map +1 -1
- package/dist/fondue-components89.js +15 -3
- package/dist/fondue-components89.js.map +1 -1
- package/dist/fondue-components9.js +92 -88
- package/dist/fondue-components9.js.map +1 -1
- package/dist/fondue-components90.js +2 -5
- package/dist/fondue-components90.js.map +1 -1
- package/dist/fondue-components91.js +39 -16
- package/dist/fondue-components91.js.map +1 -1
- package/dist/fondue-components92.js +20 -39
- package/dist/fondue-components92.js.map +1 -1
- package/dist/index.d.ts +58 -118
- package/dist/style.css +1 -1
- package/package.json +10 -7
- package/dist/fondue-components93.js +0 -9
- package/dist/fondue-components93.js.map +0 -1
|
@@ -1,71 +1,29 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
}, b = ({
|
|
25
|
-
activeTab: e
|
|
26
|
-
}) => {
|
|
27
|
-
const s = W(null), f = W(null), [t, c] = p([]), [u, r] = p([]);
|
|
28
|
-
return w(() => {
|
|
29
|
-
const o = s.current, n = o == null ? void 0 : o.querySelector('[data-state="active"]');
|
|
30
|
-
n instanceof HTMLButtonElement && o instanceof HTMLDivElement && (a(o, f), n.scrollIntoView({ behavior: "smooth", block: "nearest", inline: "end" }));
|
|
31
|
-
}, [e, f]), I(() => {
|
|
32
|
-
var i;
|
|
33
|
-
const o = s.current, n = o == null ? void 0 : o.querySelector('[data-state="active"]');
|
|
34
|
-
if (o instanceof HTMLDivElement && n instanceof HTMLButtonElement) {
|
|
35
|
-
a(o, f);
|
|
36
|
-
const d = new MutationObserver(() => {
|
|
37
|
-
n.scrollIntoView({ behavior: "instant", block: "nearest", inline: "end" }), a(o, f);
|
|
38
|
-
});
|
|
39
|
-
o.parentNode && d.observe(o.parentNode, { childList: !0 });
|
|
40
|
-
const h = new IntersectionObserver(
|
|
41
|
-
() => {
|
|
42
|
-
r(T(t, o)), a(o, f);
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
root: o,
|
|
46
|
-
threshold: 1
|
|
47
|
-
}
|
|
48
|
-
);
|
|
49
|
-
for (const v of t)
|
|
50
|
-
(i = v.ref) != null && i.current && h.observe(v.ref.current);
|
|
51
|
-
return () => {
|
|
52
|
-
h.disconnect(), d.disconnect();
|
|
53
|
-
};
|
|
54
|
-
}
|
|
55
|
-
}, [t, s, f]), {
|
|
56
|
-
triggerListRef: s,
|
|
57
|
-
activeIndicatorRef: f,
|
|
58
|
-
triggersOutOfView: u,
|
|
59
|
-
triggers: t,
|
|
60
|
-
addTrigger: (o) => {
|
|
61
|
-
o.previousElement || c((n) => [...n, o]), c((n) => {
|
|
62
|
-
const i = n.findIndex((d) => d.element === o.previousElement);
|
|
63
|
-
return n[i] = o, [...n];
|
|
64
|
-
});
|
|
65
|
-
}
|
|
66
|
-
};
|
|
1
|
+
const o = "_root_1cjgh_2", _ = {
|
|
2
|
+
root: o,
|
|
3
|
+
"weight-default": "_weight-default_1cjgh_7",
|
|
4
|
+
"weight-strong": "_weight-strong_1cjgh_11",
|
|
5
|
+
"weight-x-strong": "_weight-x-strong_1cjgh_15",
|
|
6
|
+
"size-x-small": "_size-x-small_1cjgh_19",
|
|
7
|
+
"size-small": "_size-small_1cjgh_24",
|
|
8
|
+
"size-medium": "_size-medium_1cjgh_29",
|
|
9
|
+
"size-large": "_size-large_1cjgh_34",
|
|
10
|
+
"color-default": "_color-default_1cjgh_39",
|
|
11
|
+
"color-weak": "_color-weak_1cjgh_43",
|
|
12
|
+
"color-x-weak": "_color-x-weak_1cjgh_47",
|
|
13
|
+
"color-disabled": "_color-disabled_1cjgh_51",
|
|
14
|
+
"color-negative": "_color-negative_1cjgh_55",
|
|
15
|
+
"color-positive": "_color-positive_1cjgh_59",
|
|
16
|
+
"color-warning": "_color-warning_1cjgh_63",
|
|
17
|
+
"color-interactive": "_color-interactive_1cjgh_67",
|
|
18
|
+
"color-box-neutral": "_color-box-neutral_1cjgh_71",
|
|
19
|
+
"color-box-selected": "_color-box-selected_1cjgh_75",
|
|
20
|
+
"color-box-disabled": "_color-box-disabled_1cjgh_79",
|
|
21
|
+
"color-box-positive": "_color-box-positive_1cjgh_83",
|
|
22
|
+
"color-box-negative": "_color-box-negative_1cjgh_87",
|
|
23
|
+
"color-box-warning": "_color-box-warning_1cjgh_91"
|
|
67
24
|
};
|
|
68
25
|
export {
|
|
69
|
-
|
|
26
|
+
_ as default,
|
|
27
|
+
o as root
|
|
70
28
|
};
|
|
71
29
|
//# sourceMappingURL=fondue-components81.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fondue-components81.js","sources":["../src/components/Tabs/hooks/useTabTriggers.ts"],"sourcesContent":["/* (c) Copyright Frontify Ltd., all rights reserved. */\n\nimport { type RefObject, useEffect, useLayoutEffect, useRef, useState } from 'react';\n\nimport { type TabTrigger } from '../types';\n\nconst getOverflowingTriggers = (triggers: TabTrigger[], triggerListElement: HTMLDivElement) => {\n return triggers.filter((trigger) => {\n const triggerElement = trigger.ref?.current;\n if (!triggerElement) {\n return false;\n }\n return (\n triggerElement.offsetLeft + triggerElement.offsetWidth >\n triggerListElement?.scrollLeft + triggerListElement.offsetWidth ||\n triggerElement.offsetLeft - triggerListElement.scrollLeft < 0\n );\n });\n};\n\nconst moveActiveIndicator = (triggerListElement: HTMLDivElement, activeIndicatorRef: RefObject<HTMLSpanElement>) => {\n const activeIndicatorElement = activeIndicatorRef.current;\n const activeTriggerElement = triggerListElement?.querySelector('[data-state=\"active\"]');\n\n if (\n !triggerListElement ||\n !(activeTriggerElement instanceof HTMLButtonElement) ||\n !(activeIndicatorElement instanceof HTMLSpanElement)\n ) {\n return;\n }\n\n // Get the computed direction to handle RTL correctly\n const direction = getComputedStyle(triggerListElement).direction;\n const isRTL = direction === 'rtl';\n\n const isOverflowingLeft = triggerListElement?.scrollLeft > activeTriggerElement?.offsetLeft;\n const isOverflowingRight =\n activeTriggerElement?.offsetLeft + activeTriggerElement?.offsetWidth > triggerListElement?.offsetWidth;\n\n // Helper function to calculate position based on direction\n const getInlineStartPosition = (position: number) => {\n if (isRTL) {\n // In RTL, insetInlineStart maps to 'right', so we need to calculate from the right edge\n return triggerListElement.offsetWidth - position - activeTriggerElement.offsetWidth;\n }\n return position;\n };\n\n if (isOverflowingLeft) {\n const willFitAllItemsToTheLeft =\n triggerListElement.offsetWidth > activeTriggerElement.offsetWidth + activeTriggerElement.offsetLeft;\n if (willFitAllItemsToTheLeft) {\n activeIndicatorElement.style.insetInlineStart = `${getInlineStartPosition(activeTriggerElement.offsetLeft)}px`;\n } else {\n const position = triggerListElement.offsetWidth - activeTriggerElement.offsetWidth;\n activeIndicatorElement.style.insetInlineStart = `${getInlineStartPosition(position)}px`;\n }\n activeIndicatorElement.style.width = `${activeTriggerElement?.offsetWidth}px`;\n } else if (isOverflowingRight) {\n const position = triggerListElement.clientWidth - activeTriggerElement.offsetWidth;\n activeIndicatorElement.style.insetInlineStart = `${getInlineStartPosition(position)}px`;\n activeIndicatorElement.style.width = `${activeTriggerElement.offsetWidth}px`;\n } else {\n activeIndicatorElement.style.insetInlineStart = `${getInlineStartPosition(activeTriggerElement.offsetLeft)}px`;\n activeIndicatorElement.style.width = `${activeTriggerElement.offsetWidth}px`;\n }\n};\n\nexport const useTabTriggers = ({\n activeTab,\n}: {\n activeTab?: string;\n}): {\n triggerListRef: RefObject<HTMLDivElement>;\n activeIndicatorRef: RefObject<HTMLSpanElement>;\n triggers: TabTrigger[];\n triggersOutOfView: TabTrigger[];\n addTrigger: (trigger: TabTrigger) => void;\n} => {\n const triggerListRef = useRef<HTMLDivElement | null>(null);\n const activeIndicatorRef = useRef<HTMLSpanElement | null>(null);\n const [triggers, setTriggers] = useState<TabTrigger[]>([]);\n const [triggersOutOfView, setTriggersOutOfView] = useState<TabTrigger[]>([]);\n\n // move the active indicator and scroll to the correct position when the tab changes\n useEffect(() => {\n const triggerListElement = triggerListRef.current;\n const activeTriggerElement = triggerListElement?.querySelector('[data-state=\"active\"]');\n\n if (activeTriggerElement instanceof HTMLButtonElement && triggerListElement instanceof HTMLDivElement) {\n moveActiveIndicator(triggerListElement, activeIndicatorRef);\n activeTriggerElement.scrollIntoView({ behavior: 'smooth', block: 'nearest', inline: 'end' });\n }\n }, [activeTab, activeIndicatorRef]);\n\n useLayoutEffect(() => {\n const triggerListElement = triggerListRef.current;\n const activeTriggerElement = triggerListElement?.querySelector('[data-state=\"active\"]');\n\n if (triggerListElement instanceof HTMLDivElement && activeTriggerElement instanceof HTMLButtonElement) {\n // move the active indicator to the initial active tab\n moveActiveIndicator(triggerListElement, activeIndicatorRef);\n\n // observe addition of the dropdown trigger which reduces the available width\n const mutationObserver = new MutationObserver(() => {\n activeTriggerElement.scrollIntoView({ behavior: 'instant', block: 'nearest', inline: 'end' });\n moveActiveIndicator(triggerListElement, activeIndicatorRef);\n });\n if (triggerListElement.parentNode) {\n mutationObserver.observe(triggerListElement.parentNode, { childList: true });\n }\n\n // calculate the overflowing elements when item starts overflowing the parent\n const intersectionObserver = new IntersectionObserver(\n () => {\n setTriggersOutOfView(getOverflowingTriggers(triggers, triggerListElement));\n moveActiveIndicator(triggerListElement, activeIndicatorRef);\n },\n {\n root: triggerListElement,\n threshold: 1,\n },\n );\n for (const trigger of triggers) {\n if (trigger.ref?.current) {\n intersectionObserver.observe(trigger.ref.current);\n }\n }\n\n return () => {\n intersectionObserver.disconnect();\n mutationObserver.disconnect();\n };\n }\n }, [triggers, triggerListRef, activeIndicatorRef]);\n\n const addTrigger = (trigger: TabTrigger) => {\n if (!trigger.previousElement) {\n setTriggers((prev) => [...prev, trigger]);\n }\n\n setTriggers((prev) => {\n const index = prev.findIndex((element) => element.element === trigger.previousElement);\n prev[index] = trigger;\n return [...prev];\n });\n };\n\n return {\n triggerListRef,\n activeIndicatorRef,\n triggersOutOfView,\n triggers,\n addTrigger,\n };\n};\n"],"names":["getOverflowingTriggers","triggers","triggerListElement","trigger","triggerElement","_a","moveActiveIndicator","activeIndicatorRef","activeIndicatorElement","activeTriggerElement","isRTL","isOverflowingLeft","isOverflowingRight","getInlineStartPosition","position","useTabTriggers","activeTab","triggerListRef","useRef","setTriggers","useState","triggersOutOfView","setTriggersOutOfView","useEffect","useLayoutEffect","mutationObserver","intersectionObserver","prev","index","element"],"mappings":";AAMA,MAAMA,IAAyB,CAACC,GAAwBC,MAC7CD,EAAS,OAAO,CAACE,MAAY;;AAChC,QAAMC,KAAiBC,IAAAF,EAAQ,QAAR,gBAAAE,EAAa;AACpC,SAAKD,IAIDA,EAAe,aAAaA,EAAe,eACvCF,KAAA,gBAAAA,EAAoB,cAAaA,EAAmB,eACxDE,EAAe,aAAaF,EAAmB,aAAa,IALrD;AAOf,CAAC,GAGCI,IAAsB,CAACJ,GAAoCK,MAAmD;AAChH,QAAMC,IAAyBD,EAAmB,SAC5CE,IAAuBP,KAAA,gBAAAA,EAAoB,cAAc;AAE/D,MACI,CAACA,KACD,EAAEO,aAAgC,sBAClC,EA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AACE,MAAwB;AACxC,MAAKA,EAAQ,mBACTgB,EAAY,CAACQ,MAAS,CAAC,GAAGA,GAAMxB,CAAO,CAAC,GAG5CgB,EAAY,CAACQ,MAAS;AAClB,cAAMC,IAAQD,EAAK,UAAU,CAACE,MAAYA,EAAQ,YAAY1B,EAAQ,eAAe;AACrF,eAAAwB,EAAKC,CAAK,IAAIzB,GACP,CAAC,GAAGwB,CAAI;AAAA,MACnB,CAAC;AAAA,IACL;AAAA,EAOI;AAER;"}
|
|
1
|
+
{"version":3,"file":"fondue-components81.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,18 +1,22 @@
|
|
|
1
|
-
const t = "
|
|
2
|
-
root:
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
const o = "_root_sv5hj_5", s = "_slot_sv5hj_64", t = "_input_sv5hj_64", c = "_placeholder_sv5hj_69", n = "_iconSuccess_sv5hj_139", _ = "_iconError_sv5hj_147", r = "_loadingStatus_sv5hj_160", p = "_inputWrapper_sv5hj_196", e = {
|
|
2
|
+
root: o,
|
|
3
|
+
slot: s,
|
|
4
|
+
input: t,
|
|
5
|
+
placeholder: c,
|
|
6
|
+
iconSuccess: n,
|
|
7
|
+
iconError: _,
|
|
8
|
+
loadingStatus: r,
|
|
9
|
+
inputWrapper: p
|
|
8
10
|
};
|
|
9
11
|
export {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
t as
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
12
|
+
e as default,
|
|
13
|
+
_ as iconError,
|
|
14
|
+
n as iconSuccess,
|
|
15
|
+
t as input,
|
|
16
|
+
p as inputWrapper,
|
|
17
|
+
r as loadingStatus,
|
|
18
|
+
c as placeholder,
|
|
19
|
+
o as root,
|
|
20
|
+
s as slot
|
|
17
21
|
};
|
|
18
22
|
//# sourceMappingURL=fondue-components82.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fondue-components82.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fondue-components82.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;"}
|
|
@@ -1,28 +1,26 @@
|
|
|
1
|
-
const o = "
|
|
1
|
+
const o = "_root_18lbr_5", t = "_textarea_18lbr_73", s = "_slot_18lbr_123", r = "_decorator_18lbr_137", _ = "_tools_18lbr_150", l = "_toolsButton_18lbr_162", c = "_success_18lbr_194", n = "_error_18lbr_198", e = "_loadingStatus_18lbr_202", a = "_spin_18lbr_1", b = {
|
|
2
2
|
root: o,
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
"color-disabled": "_color-disabled_1m55x_47",
|
|
13
|
-
"color-negative": "_color-negative_1m55x_51",
|
|
14
|
-
"color-positive": "_color-positive_1m55x_55",
|
|
15
|
-
"color-warning": "_color-warning_1m55x_59",
|
|
16
|
-
"color-interactive": "_color-interactive_1m55x_63",
|
|
17
|
-
"color-box-neutral": "_color-box-neutral_1m55x_67",
|
|
18
|
-
"color-box-selected": "_color-box-selected_1m55x_71",
|
|
19
|
-
"color-box-disabled": "_color-box-disabled_1m55x_75",
|
|
20
|
-
"color-box-positive": "_color-box-positive_1m55x_79",
|
|
21
|
-
"color-box-negative": "_color-box-negative_1m55x_83",
|
|
22
|
-
"color-box-warning": "_color-box-warning_1m55x_87"
|
|
3
|
+
textarea: t,
|
|
4
|
+
slot: s,
|
|
5
|
+
decorator: r,
|
|
6
|
+
tools: _,
|
|
7
|
+
toolsButton: l,
|
|
8
|
+
success: c,
|
|
9
|
+
error: n,
|
|
10
|
+
loadingStatus: e,
|
|
11
|
+
spin: a
|
|
23
12
|
};
|
|
24
13
|
export {
|
|
25
|
-
|
|
26
|
-
|
|
14
|
+
r as decorator,
|
|
15
|
+
b as default,
|
|
16
|
+
n as error,
|
|
17
|
+
e as loadingStatus,
|
|
18
|
+
o as root,
|
|
19
|
+
s as slot,
|
|
20
|
+
a as spin,
|
|
21
|
+
c as success,
|
|
22
|
+
t as textarea,
|
|
23
|
+
_ as tools,
|
|
24
|
+
l as toolsButton
|
|
27
25
|
};
|
|
28
26
|
//# sourceMappingURL=fondue-components83.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fondue-components83.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fondue-components83.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;"}
|
|
@@ -1,22 +1,10 @@
|
|
|
1
|
-
const
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
input: c,
|
|
5
|
-
placeholder: n,
|
|
6
|
-
iconSuccess: s,
|
|
7
|
-
iconError: _,
|
|
8
|
-
loadingStatus: r,
|
|
9
|
-
inputWrapper: y
|
|
1
|
+
const t = "_dark_1mr83_1", r = "_light_1mr83_250", s = {
|
|
2
|
+
dark: t,
|
|
3
|
+
light: r
|
|
10
4
|
};
|
|
11
5
|
export {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
c as input,
|
|
16
|
-
y as inputWrapper,
|
|
17
|
-
r as loadingStatus,
|
|
18
|
-
n as placeholder,
|
|
19
|
-
o as root,
|
|
20
|
-
t as slot
|
|
6
|
+
t as dark,
|
|
7
|
+
s as default,
|
|
8
|
+
r as light
|
|
21
9
|
};
|
|
22
10
|
//# sourceMappingURL=fondue-components84.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fondue-components84.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fondue-components84.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
|
@@ -1,26 +1,23 @@
|
|
|
1
|
-
const
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
1
|
+
const e = {
|
|
2
|
+
ColorPicker_selectColor: "Select Color",
|
|
3
|
+
ColorPicker_selectFormat: "Select a color format",
|
|
4
|
+
ColorPicker_hexValue: "Hex color value",
|
|
5
|
+
ColorPicker_redChannel: "Red Color Channel",
|
|
6
|
+
ColorPicker_greenChannel: "Green Color Channel",
|
|
7
|
+
ColorPicker_blueChannel: "Blue Color Channel",
|
|
8
|
+
ColorPicker_opacity: "Color Opacity",
|
|
9
|
+
Dialog_close: "Close",
|
|
10
|
+
Flyout_close: "Close",
|
|
11
|
+
Select_clear: "clear input",
|
|
12
|
+
Select_toggleMenu: "toggle menu",
|
|
13
|
+
Switch_defaultLabel: "Switch",
|
|
14
|
+
Table_sortByDescending: "Sort by ${column} descending",
|
|
15
|
+
Table_sortByAscending: "Sort by ${column} ascending",
|
|
16
|
+
Table_sortDescending: "Sort descending",
|
|
17
|
+
Table_sortAscending: "Sort ascending",
|
|
18
|
+
Badge_dismiss: "Dismiss ${label}"
|
|
12
19
|
};
|
|
13
20
|
export {
|
|
14
|
-
|
|
15
|
-
p as default,
|
|
16
|
-
n as error,
|
|
17
|
-
a as loadingStatus,
|
|
18
|
-
o as root,
|
|
19
|
-
t as slot,
|
|
20
|
-
l as spin,
|
|
21
|
-
c as success,
|
|
22
|
-
s as textarea,
|
|
23
|
-
_ as tools,
|
|
24
|
-
e as toolsButton
|
|
21
|
+
e as enUS
|
|
25
22
|
};
|
|
26
23
|
//# sourceMappingURL=fondue-components85.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fondue-components85.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fondue-components85.js","sources":["../src/locales/en-US.ts"],"sourcesContent":["/* (c) Copyright Frontify Ltd., all rights reserved. */\n\nexport const enUS = {\n ColorPicker_selectColor: 'Select Color',\n ColorPicker_selectFormat: 'Select a color format',\n ColorPicker_hexValue: 'Hex color value',\n ColorPicker_redChannel: 'Red Color Channel',\n ColorPicker_greenChannel: 'Green Color Channel',\n ColorPicker_blueChannel: 'Blue Color Channel',\n ColorPicker_opacity: 'Color Opacity',\n Dialog_close: 'Close',\n Flyout_close: 'Close',\n Select_clear: 'clear input',\n Select_toggleMenu: 'toggle menu',\n Switch_defaultLabel: 'Switch',\n Table_sortByDescending: 'Sort by ${column} descending',\n Table_sortByAscending: 'Sort by ${column} ascending',\n Table_sortDescending: 'Sort descending',\n Table_sortAscending: 'Sort ascending',\n Badge_dismiss: 'Dismiss ${label}',\n};\n"],"names":["enUS"],"mappings":"AAEO,MAAMA,IAAO;AAAA,EAChB,yBAAyB;AAAA,EACzB,0BAA0B;AAAA,EAC1B,sBAAsB;AAAA,EACtB,wBAAwB;AAAA,EACxB,0BAA0B;AAAA,EAC1B,yBAAyB;AAAA,EACzB,qBAAqB;AAAA,EACrB,cAAc;AAAA,EACd,cAAc;AAAA,EACd,cAAc;AAAA,EACd,mBAAmB;AAAA,EACnB,qBAAqB;AAAA,EACrB,wBAAwB;AAAA,EACxB,uBAAuB;AAAA,EACvB,sBAAsB;AAAA,EACtB,qBAAqB;AAAA,EACrB,eAAe;AACnB;"}
|
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
const
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
light: t
|
|
1
|
+
const o = "_root_17g9r_4", r = "_arrow_17g9r_27", t = {
|
|
2
|
+
root: o,
|
|
3
|
+
arrow: r
|
|
5
4
|
};
|
|
6
5
|
export {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
t as light
|
|
6
|
+
r as arrow,
|
|
7
|
+
t as default,
|
|
8
|
+
o as root
|
|
11
9
|
};
|
|
12
10
|
//# sourceMappingURL=fondue-components86.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fondue-components86.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fondue-components86.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fondue-components87.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fondue-components87.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;"}
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
const
|
|
1
|
+
const r = (e) => {
|
|
2
|
+
if (e)
|
|
3
|
+
return `rgba(${e.red}, ${e.green}, ${e.blue}, ${e.alpha ?? 1})`;
|
|
4
|
+
};
|
|
2
5
|
export {
|
|
3
|
-
|
|
6
|
+
r as colorToCss
|
|
4
7
|
};
|
|
5
8
|
//# sourceMappingURL=fondue-components88.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fondue-components88.js","sources":["../src/
|
|
1
|
+
{"version":3,"file":"fondue-components88.js","sources":["../src/components/Badge/utils.ts"],"sourcesContent":["/* (c) Copyright Frontify Ltd., all rights reserved. */\n\nimport { type RgbaColor } from './types';\n\nexport const DEFAULT_COLOR = { red: 255, green: 255, blue: 255, alpha: 1, name: '' };\n\n/**\n * Converts a color object to a CSS color string.\n * @param {RgbaColor} color - The color object to be converted.\n * @returns {string}\n * @example\n * colorToCss({ red: 255, green: 255, blue: 255, alpha: 1 }); // 'rgba(255, 255, 255, 1)'\n * @example\n * colorToCss({ red: 255, green: 87, blue: 51, alpha: 1 }); // 'rgba(255, 87, 51, 1)'\n * @example\n * colorToCss({ red: 0, green: 0, blue: 0, alpha: 0 }); // 'rgba(0, 0, 0, 0)'\n */\nexport const colorToCss = (color?: RgbaColor) => {\n if (!color) {\n return undefined;\n }\n return `rgba(${color.red}, ${color.green}, ${color.blue}, ${color.alpha ?? 1})`;\n};\n"],"names":["colorToCss","color"],"mappings":"AAiBO,MAAMA,IAAa,CAACC,MAAsB;AAC7C,MAAKA;AAGL,WAAO,QAAQA,EAAM,GAAG,KAAKA,EAAM,KAAK,KAAKA,EAAM,IAAI,KAAKA,EAAM,SAAS,CAAC;AAChF;"}
|
|
@@ -1,8 +1,20 @@
|
|
|
1
|
-
const o = "
|
|
2
|
-
root: o
|
|
1
|
+
const o = "_root_3jye8_5", c = "_clearIcon_3jye8_35", t = "_caret_3jye8_52", _ = "_colorName_3jye8_72", n = "_button_3jye8_93", e = "_colorIndicator_3jye8_105", r = "_actions_3jye8_124", a = {
|
|
2
|
+
root: o,
|
|
3
|
+
clearIcon: c,
|
|
4
|
+
caret: t,
|
|
5
|
+
colorName: _,
|
|
6
|
+
button: n,
|
|
7
|
+
colorIndicator: e,
|
|
8
|
+
actions: r
|
|
3
9
|
};
|
|
4
10
|
export {
|
|
5
|
-
|
|
11
|
+
r as actions,
|
|
12
|
+
n as button,
|
|
13
|
+
t as caret,
|
|
14
|
+
c as clearIcon,
|
|
15
|
+
e as colorIndicator,
|
|
16
|
+
_ as colorName,
|
|
17
|
+
a as default,
|
|
6
18
|
o as root
|
|
7
19
|
};
|
|
8
20
|
//# sourceMappingURL=fondue-components89.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fondue-components89.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fondue-components89.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;"}
|