@pequity/squirrel 5.4.11 → 6.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/cjs/chunks/p-icon.js +157 -49
- package/dist/cjs/chunks/p-link.js +1 -0
- package/dist/cjs/p-dropdown.js +37 -31
- package/dist/cjs/p-modal.js +10 -7
- package/dist/cjs/p-select-pill.js +2 -1
- package/dist/es/chunks/p-icon.js +157 -49
- package/dist/es/chunks/p-link.js +1 -0
- package/dist/es/p-dropdown.js +37 -31
- package/dist/es/p-modal.js +10 -7
- package/dist/es/p-select-pill.js +2 -1
- package/dist/squirrel/components/p-dropdown/p-dropdown.vue.d.ts +406 -24
- package/dist/{style.css → squirrel.css} +14 -14
- package/package.json +37 -37
- package/squirrel/components/p-dropdown/p-dropdown.spec.js +2 -2
- package/squirrel/components/p-dropdown/p-dropdown.vue +55 -33
- package/squirrel/components/p-modal/p-modal.vue +2 -2
- package/squirrel/components/p-select-pill/p-select-pill.spec.js +2 -0
- package/squirrel/components/p-select-pill/p-select-pill.vue +1 -0
- package/squirrel/utils/tailwind.spec.js +1 -1
|
@@ -13,7 +13,7 @@ const pIcon = require("../p-icon.js");
|
|
|
13
13
|
* Licensed under MIT.
|
|
14
14
|
*
|
|
15
15
|
* @license MIT
|
|
16
|
-
* @version 2.
|
|
16
|
+
* @version 2.2.0
|
|
17
17
|
*/
|
|
18
18
|
const defaultIconDimensions = Object.freeze(
|
|
19
19
|
{
|
|
@@ -163,7 +163,9 @@ const validateIconName = (icon, allowSimpleName) => {
|
|
|
163
163
|
if (!icon) {
|
|
164
164
|
return false;
|
|
165
165
|
}
|
|
166
|
-
return
|
|
166
|
+
return !!// Check prefix: cannot be empty, unless allowSimpleName is enabled
|
|
167
|
+
// Check name: cannot be empty
|
|
168
|
+
((allowSimpleName && icon.prefix === "" || !!icon.prefix) && !!icon.name);
|
|
167
169
|
};
|
|
168
170
|
function mergeIconTransformations(obj1, obj2) {
|
|
169
171
|
const result = {};
|
|
@@ -278,10 +280,15 @@ function quicklyValidateIconSet(obj) {
|
|
|
278
280
|
const icons = data.icons;
|
|
279
281
|
for (const name in icons) {
|
|
280
282
|
const icon = icons[name];
|
|
281
|
-
if (
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
283
|
+
if (
|
|
284
|
+
// Name cannot be empty
|
|
285
|
+
!name || // Must have body
|
|
286
|
+
typeof icon.body !== "string" || // Check other props
|
|
287
|
+
!checkOptionalProps(
|
|
288
|
+
icon,
|
|
289
|
+
defaultExtendedIconProps
|
|
290
|
+
)
|
|
291
|
+
) {
|
|
285
292
|
return null;
|
|
286
293
|
}
|
|
287
294
|
}
|
|
@@ -289,10 +296,15 @@ function quicklyValidateIconSet(obj) {
|
|
|
289
296
|
for (const name in aliases) {
|
|
290
297
|
const icon = aliases[name];
|
|
291
298
|
const parent = icon.parent;
|
|
292
|
-
if (
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
299
|
+
if (
|
|
300
|
+
// Name cannot be empty
|
|
301
|
+
!name || // Parent must be set and point to existing icon
|
|
302
|
+
typeof parent !== "string" || !icons[parent] && !aliases[parent] || // Check other props
|
|
303
|
+
!checkOptionalProps(
|
|
304
|
+
icon,
|
|
305
|
+
defaultExtendedIconProps
|
|
306
|
+
)
|
|
307
|
+
) {
|
|
296
308
|
return null;
|
|
297
309
|
}
|
|
298
310
|
}
|
|
@@ -370,7 +382,12 @@ function addIcon$1(name, data) {
|
|
|
370
382
|
return false;
|
|
371
383
|
}
|
|
372
384
|
const storage2 = getStorage(icon.provider, icon.prefix);
|
|
373
|
-
|
|
385
|
+
if (data) {
|
|
386
|
+
return addIconToStorage(storage2, icon.name, data);
|
|
387
|
+
} else {
|
|
388
|
+
storage2.missing.add(icon.name);
|
|
389
|
+
return true;
|
|
390
|
+
}
|
|
374
391
|
}
|
|
375
392
|
function addCollection$1(data, provider) {
|
|
376
393
|
if (typeof data !== "object") {
|
|
@@ -384,7 +401,7 @@ function addCollection$1(data, provider) {
|
|
|
384
401
|
if (quicklyValidateIconSet(data)) {
|
|
385
402
|
data.prefix = "";
|
|
386
403
|
parseIconSet(data, (name, icon) => {
|
|
387
|
-
if (
|
|
404
|
+
if (addIcon$1(name, icon)) {
|
|
388
405
|
added = true;
|
|
389
406
|
}
|
|
390
407
|
});
|
|
@@ -410,7 +427,7 @@ function getIcon$1(name) {
|
|
|
410
427
|
return result ? {
|
|
411
428
|
...defaultIconProps,
|
|
412
429
|
...result
|
|
413
|
-
} :
|
|
430
|
+
} : result;
|
|
414
431
|
}
|
|
415
432
|
function sortIcons(icons) {
|
|
416
433
|
const result = {
|
|
@@ -1070,6 +1087,57 @@ function loadedNewIcons(storage2) {
|
|
|
1070
1087
|
});
|
|
1071
1088
|
}
|
|
1072
1089
|
}
|
|
1090
|
+
function checkIconNamesForAPI(icons) {
|
|
1091
|
+
const valid = [];
|
|
1092
|
+
const invalid = [];
|
|
1093
|
+
icons.forEach((name) => {
|
|
1094
|
+
(name.match(matchIconName) ? valid : invalid).push(name);
|
|
1095
|
+
});
|
|
1096
|
+
return {
|
|
1097
|
+
valid,
|
|
1098
|
+
invalid
|
|
1099
|
+
};
|
|
1100
|
+
}
|
|
1101
|
+
function parseLoaderResponse(storage2, icons, data, isAPIResponse) {
|
|
1102
|
+
function checkMissing() {
|
|
1103
|
+
const pending = storage2.pendingIcons;
|
|
1104
|
+
icons.forEach((name) => {
|
|
1105
|
+
if (pending) {
|
|
1106
|
+
pending.delete(name);
|
|
1107
|
+
}
|
|
1108
|
+
if (!storage2.icons[name]) {
|
|
1109
|
+
storage2.missing.add(name);
|
|
1110
|
+
}
|
|
1111
|
+
});
|
|
1112
|
+
}
|
|
1113
|
+
if (data && typeof data === "object") {
|
|
1114
|
+
try {
|
|
1115
|
+
const parsed = addIconSet(storage2, data);
|
|
1116
|
+
if (!parsed.length) {
|
|
1117
|
+
checkMissing();
|
|
1118
|
+
return;
|
|
1119
|
+
}
|
|
1120
|
+
if (isAPIResponse) {
|
|
1121
|
+
storeInBrowserStorage(storage2, data);
|
|
1122
|
+
}
|
|
1123
|
+
} catch (err) {
|
|
1124
|
+
console.error(err);
|
|
1125
|
+
}
|
|
1126
|
+
}
|
|
1127
|
+
checkMissing();
|
|
1128
|
+
loadedNewIcons(storage2);
|
|
1129
|
+
}
|
|
1130
|
+
function parsePossiblyAsyncResponse(response, callback) {
|
|
1131
|
+
if (response instanceof Promise) {
|
|
1132
|
+
response.then((data) => {
|
|
1133
|
+
callback(data);
|
|
1134
|
+
}).catch(() => {
|
|
1135
|
+
callback(null);
|
|
1136
|
+
});
|
|
1137
|
+
} else {
|
|
1138
|
+
callback(response);
|
|
1139
|
+
}
|
|
1140
|
+
}
|
|
1073
1141
|
function loadNewIcons(storage2, icons) {
|
|
1074
1142
|
if (!storage2.iconsToLoad) {
|
|
1075
1143
|
storage2.iconsToLoad = icons;
|
|
@@ -1083,38 +1151,50 @@ function loadNewIcons(storage2, icons) {
|
|
|
1083
1151
|
const { provider, prefix } = storage2;
|
|
1084
1152
|
const icons2 = storage2.iconsToLoad;
|
|
1085
1153
|
delete storage2.iconsToLoad;
|
|
1086
|
-
|
|
1087
|
-
|
|
1154
|
+
if (!icons2 || !icons2.length) {
|
|
1155
|
+
return;
|
|
1156
|
+
}
|
|
1157
|
+
const customIconLoader = storage2.loadIcon;
|
|
1158
|
+
if (storage2.loadIcons && (icons2.length > 1 || !customIconLoader)) {
|
|
1159
|
+
parsePossiblyAsyncResponse(
|
|
1160
|
+
storage2.loadIcons(icons2, prefix, provider),
|
|
1161
|
+
(data) => {
|
|
1162
|
+
parseLoaderResponse(storage2, icons2, data, false);
|
|
1163
|
+
}
|
|
1164
|
+
);
|
|
1088
1165
|
return;
|
|
1089
1166
|
}
|
|
1090
|
-
|
|
1167
|
+
if (customIconLoader) {
|
|
1168
|
+
icons2.forEach((name) => {
|
|
1169
|
+
const response = customIconLoader(name, prefix, provider);
|
|
1170
|
+
parsePossiblyAsyncResponse(response, (data) => {
|
|
1171
|
+
const iconSet = data ? {
|
|
1172
|
+
prefix,
|
|
1173
|
+
icons: {
|
|
1174
|
+
[name]: data
|
|
1175
|
+
}
|
|
1176
|
+
} : null;
|
|
1177
|
+
parseLoaderResponse(storage2, [name], iconSet, false);
|
|
1178
|
+
});
|
|
1179
|
+
});
|
|
1180
|
+
return;
|
|
1181
|
+
}
|
|
1182
|
+
const { valid, invalid } = checkIconNamesForAPI(icons2);
|
|
1183
|
+
if (invalid.length) {
|
|
1184
|
+
parseLoaderResponse(storage2, invalid, null, false);
|
|
1185
|
+
}
|
|
1186
|
+
if (!valid.length) {
|
|
1187
|
+
return;
|
|
1188
|
+
}
|
|
1189
|
+
const api = prefix.match(matchIconName) ? getAPIModule(provider) : null;
|
|
1190
|
+
if (!api) {
|
|
1191
|
+
parseLoaderResponse(storage2, valid, null, false);
|
|
1192
|
+
return;
|
|
1193
|
+
}
|
|
1194
|
+
const params = api.prepare(provider, prefix, valid);
|
|
1091
1195
|
params.forEach((item) => {
|
|
1092
1196
|
sendAPIQuery(provider, item, (data) => {
|
|
1093
|
-
|
|
1094
|
-
item.icons.forEach((name) => {
|
|
1095
|
-
storage2.missing.add(name);
|
|
1096
|
-
});
|
|
1097
|
-
} else {
|
|
1098
|
-
try {
|
|
1099
|
-
const parsed = addIconSet(
|
|
1100
|
-
storage2,
|
|
1101
|
-
data
|
|
1102
|
-
);
|
|
1103
|
-
if (!parsed.length) {
|
|
1104
|
-
return;
|
|
1105
|
-
}
|
|
1106
|
-
const pending = storage2.pendingIcons;
|
|
1107
|
-
if (pending) {
|
|
1108
|
-
parsed.forEach((name) => {
|
|
1109
|
-
pending.delete(name);
|
|
1110
|
-
});
|
|
1111
|
-
}
|
|
1112
|
-
storeInBrowserStorage(storage2, data);
|
|
1113
|
-
} catch (err) {
|
|
1114
|
-
console.error(err);
|
|
1115
|
-
}
|
|
1116
|
-
}
|
|
1117
|
-
loadedNewIcons(storage2);
|
|
1197
|
+
parseLoaderResponse(storage2, item.icons, data, true);
|
|
1118
1198
|
});
|
|
1119
1199
|
});
|
|
1120
1200
|
});
|
|
@@ -1167,9 +1247,9 @@ const loadIcons$1 = (icons, callback) => {
|
|
|
1167
1247
|
}
|
|
1168
1248
|
});
|
|
1169
1249
|
sources.forEach((storage2) => {
|
|
1170
|
-
const
|
|
1171
|
-
if (
|
|
1172
|
-
loadNewIcons(storage2,
|
|
1250
|
+
const list = newIcons[storage2.provider][storage2.prefix];
|
|
1251
|
+
if (list.length) {
|
|
1252
|
+
loadNewIcons(storage2, list);
|
|
1173
1253
|
}
|
|
1174
1254
|
});
|
|
1175
1255
|
return callback ? storeCallback(callback, sortedIcons, sources) : emptyCallback;
|
|
@@ -1208,12 +1288,31 @@ function testIconObject(value) {
|
|
|
1208
1288
|
}
|
|
1209
1289
|
}
|
|
1210
1290
|
function parseIconValue(value, onload) {
|
|
1211
|
-
|
|
1212
|
-
if (!name) {
|
|
1291
|
+
if (typeof value === "object") {
|
|
1213
1292
|
const data2 = testIconObject(value);
|
|
1214
1293
|
return {
|
|
1215
|
-
|
|
1216
|
-
|
|
1294
|
+
data: data2,
|
|
1295
|
+
value
|
|
1296
|
+
};
|
|
1297
|
+
}
|
|
1298
|
+
if (typeof value !== "string") {
|
|
1299
|
+
return {
|
|
1300
|
+
value
|
|
1301
|
+
};
|
|
1302
|
+
}
|
|
1303
|
+
if (value.includes("{")) {
|
|
1304
|
+
const data2 = testIconObject(value);
|
|
1305
|
+
if (data2) {
|
|
1306
|
+
return {
|
|
1307
|
+
data: data2,
|
|
1308
|
+
value
|
|
1309
|
+
};
|
|
1310
|
+
}
|
|
1311
|
+
}
|
|
1312
|
+
const name = stringToIcon(value, true, true);
|
|
1313
|
+
if (!name) {
|
|
1314
|
+
return {
|
|
1315
|
+
value
|
|
1217
1316
|
};
|
|
1218
1317
|
}
|
|
1219
1318
|
const data = getIconData(name);
|
|
@@ -1239,6 +1338,7 @@ try {
|
|
|
1239
1338
|
}
|
|
1240
1339
|
function getRenderMode(body, mode) {
|
|
1241
1340
|
switch (mode) {
|
|
1341
|
+
// Force mode
|
|
1242
1342
|
case "svg":
|
|
1243
1343
|
case "bg":
|
|
1244
1344
|
case "mask":
|
|
@@ -1578,6 +1678,12 @@ const fetchAPIModule = {
|
|
|
1578
1678
|
prepare,
|
|
1579
1679
|
send
|
|
1580
1680
|
};
|
|
1681
|
+
function setCustomIconsLoader$1(loader, prefix, provider) {
|
|
1682
|
+
getStorage(provider || "", prefix).loadIcons = loader;
|
|
1683
|
+
}
|
|
1684
|
+
function setCustomIconLoader$1(loader, prefix, provider) {
|
|
1685
|
+
getStorage(provider || "", prefix).loadIcon = loader;
|
|
1686
|
+
}
|
|
1581
1687
|
function toggleBrowserCache(storage2, value) {
|
|
1582
1688
|
switch (storage2) {
|
|
1583
1689
|
case "local":
|
|
@@ -1603,7 +1709,7 @@ function updateStyle(parent, inline) {
|
|
|
1603
1709
|
styleNode.setAttribute(nodeAttr, nodeAttr);
|
|
1604
1710
|
parent.appendChild(styleNode);
|
|
1605
1711
|
}
|
|
1606
|
-
styleNode.textContent = ":host{display:inline-block;vertical-align:" + (inline ? "-0.125em" : "0") + "}span,svg{display:block}" + customStyle;
|
|
1712
|
+
styleNode.textContent = ":host{display:inline-block;vertical-align:" + (inline ? "-0.125em" : "0") + "}span,svg{display:block;margin:auto}" + customStyle;
|
|
1607
1713
|
}
|
|
1608
1714
|
function exportFunctions() {
|
|
1609
1715
|
setAPIModule("", fetchAPIModule);
|
|
@@ -1680,6 +1786,8 @@ function exportFunctions() {
|
|
|
1680
1786
|
loadIcons: loadIcons$1,
|
|
1681
1787
|
loadIcon: loadIcon$1,
|
|
1682
1788
|
addAPIProvider: addAPIProvider$1,
|
|
1789
|
+
setCustomIconLoader: setCustomIconLoader$1,
|
|
1790
|
+
setCustomIconsLoader: setCustomIconsLoader$1,
|
|
1683
1791
|
appendCustomStyle,
|
|
1684
1792
|
_api
|
|
1685
1793
|
};
|
package/dist/cjs/p-dropdown.js
CHANGED
|
@@ -1,10 +1,21 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const listKeyboardNavigation = require("./listKeyboardNavigation.js");
|
|
3
|
+
const floatingVue = require("floating-vue");
|
|
3
4
|
const vue = require("vue");
|
|
4
5
|
const _pluginVue_exportHelper = require("./chunks/_plugin-vue_export-helper.js");
|
|
5
6
|
const ESCAPE_KEY = "Escape";
|
|
7
|
+
const nextFrame = () => {
|
|
8
|
+
return new Promise(
|
|
9
|
+
(resolve) => requestAnimationFrame(() => {
|
|
10
|
+
requestAnimationFrame(resolve);
|
|
11
|
+
})
|
|
12
|
+
);
|
|
13
|
+
};
|
|
6
14
|
const _sfc_main = vue.defineComponent({
|
|
7
15
|
name: "PDropdown",
|
|
16
|
+
components: {
|
|
17
|
+
Dropdown: floatingVue.Dropdown
|
|
18
|
+
},
|
|
8
19
|
inheritAttrs: false,
|
|
9
20
|
props: {
|
|
10
21
|
/**
|
|
@@ -31,49 +42,24 @@ const _sfc_main = vue.defineComponent({
|
|
|
31
42
|
default: () => ({
|
|
32
43
|
display: "inline-block"
|
|
33
44
|
})
|
|
34
|
-
},
|
|
35
|
-
/**
|
|
36
|
-
* Custom reference element that is used to position the popper.
|
|
37
|
-
* Can be changed at runtime to create a dynamically positioned dropdown.
|
|
38
|
-
*/
|
|
39
|
-
reference: {
|
|
40
|
-
type: HTMLElement,
|
|
41
|
-
default: null
|
|
42
45
|
}
|
|
43
46
|
},
|
|
44
47
|
data() {
|
|
45
48
|
return {
|
|
46
49
|
defaultAttrs: {
|
|
47
50
|
triggers: ["click"],
|
|
48
|
-
|
|
51
|
+
autoHide: true,
|
|
49
52
|
theme: "p-dropdown-theme",
|
|
50
|
-
|
|
53
|
+
popperClass: "dropdown",
|
|
51
54
|
placement: "bottom-start",
|
|
52
55
|
distance: 4,
|
|
53
56
|
delay: 0,
|
|
54
57
|
handleResize: true
|
|
55
58
|
},
|
|
56
|
-
navigationSvc: null
|
|
59
|
+
navigationSvc: null,
|
|
60
|
+
prevReference: null
|
|
57
61
|
};
|
|
58
62
|
},
|
|
59
|
-
watch: {
|
|
60
|
-
reference: {
|
|
61
|
-
async handler(nV, oV) {
|
|
62
|
-
if (nV && oV !== nV) {
|
|
63
|
-
const popper = this.$refs.vPopper.$refs.popper;
|
|
64
|
-
if (popper) {
|
|
65
|
-
popper.$_detachPopperNode();
|
|
66
|
-
if (popper.shown) {
|
|
67
|
-
popper.hide({ skipDelay: true });
|
|
68
|
-
}
|
|
69
|
-
if (this.reference) {
|
|
70
|
-
popper.$_referenceNode = this.reference;
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
},
|
|
77
63
|
mounted() {
|
|
78
64
|
Object.assign(this.$refs.vPopper.$refs.popper.$el.style, this.triggerStyle);
|
|
79
65
|
},
|
|
@@ -100,12 +86,32 @@ const _sfc_main = vue.defineComponent({
|
|
|
100
86
|
var _a;
|
|
101
87
|
(_a = this.navigationSvc) == null ? void 0 : _a.destroy();
|
|
102
88
|
document.removeEventListener("keydown", this.popoverEscKeydown);
|
|
89
|
+
},
|
|
90
|
+
async updateReference(newReference) {
|
|
91
|
+
if (!newReference) {
|
|
92
|
+
throw Error("Reference element is required");
|
|
93
|
+
}
|
|
94
|
+
const popper = this.$refs.vPopper.$refs.popper;
|
|
95
|
+
if (popper) {
|
|
96
|
+
popper.$_detachPopperNode();
|
|
97
|
+
if (popper.isShown) {
|
|
98
|
+
popper.$emit("update:shown", false);
|
|
99
|
+
if (newReference === this.prevReference) {
|
|
100
|
+
return;
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
await nextFrame();
|
|
104
|
+
popper.$_referenceNode = newReference;
|
|
105
|
+
this.prevReference = newReference;
|
|
106
|
+
await nextFrame();
|
|
107
|
+
popper.$emit("update:shown", true);
|
|
108
|
+
}
|
|
103
109
|
}
|
|
104
110
|
}
|
|
105
111
|
});
|
|
106
112
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
107
|
-
const
|
|
108
|
-
return vue.openBlock(), vue.createBlock(
|
|
113
|
+
const _component_Dropdown = vue.resolveComponent("Dropdown");
|
|
114
|
+
return vue.openBlock(), vue.createBlock(_component_Dropdown, vue.mergeProps({ ref: "vPopper" }, { ..._ctx.defaultAttrs, ..._ctx.$attrs }, {
|
|
109
115
|
onShow: _ctx.onShow,
|
|
110
116
|
onHide: _ctx.destroy
|
|
111
117
|
}), vue.createSlots({ _: 2 }, [
|
package/dist/cjs/p-modal.js
CHANGED
|
@@ -15,7 +15,10 @@ const _hoisted_7 = {
|
|
|
15
15
|
class: "mb-4 px-8"
|
|
16
16
|
};
|
|
17
17
|
const _hoisted_8 = ["id"];
|
|
18
|
-
const _hoisted_9 = {
|
|
18
|
+
const _hoisted_9 = {
|
|
19
|
+
key: 0,
|
|
20
|
+
class: "px-8 pt-6"
|
|
21
|
+
};
|
|
19
22
|
const FOCUSABLE_ELEMENTS = 'a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), [tabindex]:not([tabindex="-1"])';
|
|
20
23
|
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
21
24
|
...{
|
|
@@ -111,7 +114,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
111
114
|
],
|
|
112
115
|
setup(__props, { emit: __emit }) {
|
|
113
116
|
vue.useCssVars((_ctx) => ({
|
|
114
|
-
"
|
|
117
|
+
"4895a587": __props.maxWidth
|
|
115
118
|
}));
|
|
116
119
|
let animatingZIndex = 0;
|
|
117
120
|
const emit = __emit;
|
|
@@ -352,11 +355,11 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
352
355
|
vue.renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
353
356
|
], 10, _hoisted_8)
|
|
354
357
|
], true),
|
|
355
|
-
|
|
356
|
-
vue.
|
|
358
|
+
vue.renderSlot(_ctx.$slots, "footer-wrapper", {}, () => [
|
|
359
|
+
_ctx.$slots["footer"] ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_9, [
|
|
357
360
|
vue.renderSlot(_ctx.$slots, "footer", {}, void 0, true)
|
|
358
|
-
])
|
|
359
|
-
], true)
|
|
361
|
+
])) : vue.createCommentVNode("", true)
|
|
362
|
+
], true)
|
|
360
363
|
], 14, _hoisted_3)
|
|
361
364
|
], 46, _hoisted_2), [
|
|
362
365
|
[vue.vShow, show.value]
|
|
@@ -368,5 +371,5 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
368
371
|
};
|
|
369
372
|
}
|
|
370
373
|
});
|
|
371
|
-
const pModal = /* @__PURE__ */ _pluginVue_exportHelper._export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
374
|
+
const pModal = /* @__PURE__ */ _pluginVue_exportHelper._export_sfc(_sfc_main, [["__scopeId", "data-v-5fd440a3"]]);
|
|
372
375
|
module.exports = pModal;
|
|
@@ -91,7 +91,7 @@ const _hoisted_2 = {
|
|
|
91
91
|
ref: "pill",
|
|
92
92
|
class: "absolute left-0 top-0 inline-block h-full rounded-full bg-surface duration-200 ease-in-out"
|
|
93
93
|
};
|
|
94
|
-
const _hoisted_3 = ["disabled", "onClick"];
|
|
94
|
+
const _hoisted_3 = ["disabled", "data-selected", "onClick"];
|
|
95
95
|
const _hoisted_4 = { class: "flex" };
|
|
96
96
|
const _hoisted_5 = {
|
|
97
97
|
key: 0,
|
|
@@ -109,6 +109,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
109
109
|
_ctx.modelValue === o[_ctx.itemValue] ? `${_ctx.ACTIVE_CLASS} hover:text-p-purple-70` : "hover:text-p-gray-60",
|
|
110
110
|
{ "opacity-25": o.disabled }
|
|
111
111
|
]]),
|
|
112
|
+
"data-selected": _ctx.modelValue === o[_ctx.itemValue],
|
|
112
113
|
onClick: ($event) => _ctx.click($event, o)
|
|
113
114
|
}, [
|
|
114
115
|
vue.createElementVNode("div", _hoisted_4, [
|