eco-vue-js 0.8.18 → 0.8.19

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. package/dist/components/Button/WButtonSelection.vue.d.ts.map +1 -1
  2. package/dist/components/Button/WButtonSelection.vue.js +1 -1
  3. package/dist/components/Expansion/WExpansion.vue.d.ts +6 -2
  4. package/dist/components/Expansion/WExpansion.vue.d.ts.map +1 -1
  5. package/dist/components/Expansion/WExpansion.vue.js +4 -1
  6. package/dist/components/FormAsync/WFormAsyncInput.vue.js +1 -0
  7. package/dist/components/FormAsync/WFormAsyncSelect.vue.js +1 -0
  8. package/dist/components/FormAsync/WFormAsyncSelectInfiniteSingle.vue.js +1 -0
  9. package/dist/components/FormAsync/WFormAsyncSelectSingle.vue.js +1 -0
  10. package/dist/components/FormAsync/WFormAsyncSelectStringified.vue.js +1 -0
  11. package/dist/components/InfiniteList/components/InfiniteListPage.vue.js +6 -6
  12. package/dist/components/Input/WInput.vue.js +7 -6
  13. package/dist/components/Input/WInputAsync.vue.js +1 -0
  14. package/dist/components/Input/WInputDate.vue.js +1 -0
  15. package/dist/components/Input/WInputOptions.vue.js +1 -0
  16. package/dist/components/Input/WInputSuggest.vue.js +2 -1
  17. package/dist/components/Input/types.d.ts +1 -0
  18. package/dist/components/Input/types.d.ts.map +1 -1
  19. package/dist/components/List/WList.vue.d.ts +5 -1
  20. package/dist/components/List/WList.vue.d.ts.map +1 -1
  21. package/dist/components/List/WList.vue.js +82 -31
  22. package/dist/components/List/WListCard.vue.d.ts +9 -1
  23. package/dist/components/List/WListCard.vue.d.ts.map +1 -1
  24. package/dist/components/List/WListCard.vue.js +114 -52
  25. package/dist/components/List/WListCardField.vue.d.ts.map +1 -1
  26. package/dist/components/List/WListCardField.vue.js +21 -25
  27. package/dist/components/List/WListHeader.vue.d.ts.map +1 -1
  28. package/dist/components/List/WListHeader.vue.js +36 -23
  29. package/dist/components/List/WListHeaderItem.vue.d.ts.map +1 -1
  30. package/dist/components/List/WListHeaderItem.vue.js +1 -1
  31. package/dist/components/List/types.d.ts +5 -2
  32. package/dist/components/List/types.d.ts.map +1 -1
  33. package/dist/components/Select/WSelect.vue.js +1 -0
  34. package/dist/components/Select/WSelectAsync.vue.js +1 -0
  35. package/dist/components/Select/WSelectAsyncSingle.vue.js +1 -0
  36. package/dist/components/Select/WSelectSingle.vue.js +1 -0
  37. package/dist/components/Select/WSelectStringified.vue.js +1 -0
  38. package/package.json +1 -1
  39. package/tailwind-base/plugins/default.cjs +34 -34
@@ -1 +1 @@
1
- {"version":3,"file":"WButtonSelection.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Button/WButtonSelection.vue"],"names":[],"mappings":"AAiLA,iBAAS,cAAc;;;;;YA2KM,GAAG;;;;YACL,GAAG;;;WAShB,OAAO,IAA6B;EAEjD;AAwBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;YAjQT,MAAM;qBACG,MAAM;;;;;;YADf,MAAM;qBACG,MAAM;;;;WADf,MAAM;oBACG,MAAM;6EA2QzB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAgBpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"WButtonSelection.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Button/WButtonSelection.vue"],"names":[],"mappings":"AAiLA,iBAAS,cAAc;;;;;YA8KM,GAAG;;;;YACL,GAAG;;;WAShB,OAAO,IAA6B;EAEjD;AAwBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;YApQT,MAAM;qBACG,MAAM;;;;;;YADf,MAAM;qBACG,MAAM;;;;WADf,MAAM;oBACG,MAAM;6EA8QzB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAgBpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -8,7 +8,7 @@ import { HorizontalAlign } from '../../utils/HorizontalAlign.js';
8
8
  import _sfc_main$3 from '../ClickOutside/WClickOutside.vue.js';
9
9
  import { wInfiniteListSelection } from '../InfiniteList/models/injection.js';
10
10
 
11
- const _hoisted_1 = { class: "grid grid-cols-[1fr,auto] h-12 pb-3 w-full" };
11
+ const _hoisted_1 = { class: "grid grid-cols-[1fr,auto] h-12 pb-3 w-full sm:sticky sm:left-inner sm:w-inner" };
12
12
  const _hoisted_2 = { class: "flex" };
13
13
  const _hoisted_3 = {
14
14
  key: 0,
@@ -9,10 +9,14 @@ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
9
9
  declare const __VLS_component: import('vue').DefineComponent<{
10
10
  isOpen?: boolean;
11
11
  isShown?: boolean;
12
- }, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{
12
+ }, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
13
+ "update:visible": (value: boolean) => any;
14
+ }, string, import('vue').PublicProps, Readonly<{
13
15
  isOpen?: boolean;
14
16
  isShown?: boolean;
15
- }> & Readonly<{}>, {
17
+ }> & Readonly<{
18
+ "onUpdate:visible"?: ((value: boolean) => any) | undefined;
19
+ }>, {
16
20
  isOpen: boolean;
17
21
  isShown: boolean;
18
22
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
@@ -1 +1 @@
1
- {"version":3,"file":"WExpansion.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Expansion/WExpansion.vue"],"names":[],"mappings":"AAgEA,iBAAS,cAAc;;yBAkDO,GAAG;;;WASnB,OAAO,IAA6B;EAEjD;AASD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;aA5FR,OAAO;cACN,OAAO;;aADR,OAAO;cACN,OAAO;;YADR,OAAO;aACN,OAAO;6EAkGnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAgBpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"WExpansion.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Expansion/WExpansion.vue"],"names":[],"mappings":"AA2EA,iBAAS,cAAc;;yBAyFO,GAAG;;;WASnB,OAAO,IAA6B;EAEjD;AAYD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;aA5IR,OAAO;cACN,OAAO;;;;aADR,OAAO;cACN,OAAO;;;;YADR,OAAO;aACN,OAAO;6EAqJnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAgBpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -11,6 +11,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
11
11
  isOpen: { type: Boolean, default: true },
12
12
  isShown: { type: Boolean, default: true }
13
13
  },
14
+ emits: ["update:visible"],
14
15
  setup(__props) {
15
16
  return (_ctx, _cache) => {
16
17
  return openBlock(), createBlock(Transition, {
@@ -19,7 +20,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
19
20
  "enter-to-class": "grid-rows-[1fr]",
20
21
  "leave-active-class": "transition-[grid-template-rows] overflow-hidden grid",
21
22
  "leave-from-class": "grid-rows-[1fr]",
22
- "leave-to-class": "grid-rows-[0fr]"
23
+ "leave-to-class": "grid-rows-[0fr]",
24
+ onBeforeEnter: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("update:visible", true)),
25
+ onAfterLeave: _cache[1] || (_cache[1] = ($event) => _ctx.$emit("update:visible", false))
23
26
  }, {
24
27
  default: withCtx(() => [
25
28
  (openBlock(), createBlock(KeepAlive, null, [
@@ -28,6 +28,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
28
28
  autocomplete: {},
29
29
  autofocus: { type: Boolean },
30
30
  readonly: { type: Boolean },
31
+ unclickable: { type: Boolean },
31
32
  disabledActions: { type: Boolean },
32
33
  loading: { type: Boolean },
33
34
  spellcheck: { type: Boolean },
@@ -37,6 +37,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
37
37
  autocomplete: {},
38
38
  autofocus: { type: Boolean },
39
39
  readonly: { type: Boolean },
40
+ unclickable: { type: Boolean },
40
41
  disabledActions: { type: Boolean },
41
42
  loading: { type: Boolean },
42
43
  spellcheck: { type: Boolean },
@@ -43,6 +43,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
43
43
  autocomplete: {},
44
44
  autofocus: { type: Boolean },
45
45
  readonly: { type: Boolean },
46
+ unclickable: { type: Boolean },
46
47
  disabledActions: { type: Boolean },
47
48
  loading: { type: Boolean },
48
49
  spellcheck: { type: Boolean },
@@ -38,6 +38,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
38
38
  autocomplete: {},
39
39
  autofocus: { type: Boolean },
40
40
  readonly: { type: Boolean },
41
+ unclickable: { type: Boolean },
41
42
  disabledActions: { type: Boolean },
42
43
  loading: { type: Boolean },
43
44
  spellcheck: { type: Boolean },
@@ -38,6 +38,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
38
38
  autocomplete: {},
39
39
  autofocus: { type: Boolean },
40
40
  readonly: { type: Boolean },
41
+ unclickable: { type: Boolean },
41
42
  disabledActions: { type: Boolean },
42
43
  loading: { type: Boolean },
43
44
  spellcheck: { type: Boolean },
@@ -207,12 +207,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
207
207
  class: normalizeClass(_ctx.pageClass)
208
208
  }, [
209
209
  hasData.value && unref(data)?.results ? (openBlock(), createBlock(resolveDynamicComponent(_ctx.transition ? TransitionGroup : _sfc_main$3), normalizeProps(mergeProps({ key: 0 }, _ctx.transition ? {
210
- ["enter-active-class"]: "transition-[grid-template-rows] overflow-hidden grid",
211
- ["enter-from-class"]: "grid-rows-[0fr]",
212
- ["enter-to-class"]: "grid-rows-[1fr]",
213
- ["leave-active-class"]: "transition-[grid-template-rows] overflow-hidden grid",
214
- ["leave-from-class"]: "grid-rows-[1fr]",
215
- ["leave-to-class"]: "grid-rows-[0fr]",
210
+ "enter-active-class": "transition-[grid-template-rows] overflow-hidden grid",
211
+ "enter-from-class": "grid-rows-[0fr]",
212
+ "enter-to-class": "grid-rows-[1fr]",
213
+ "leave-active-class": "transition-[grid-template-rows] overflow-hidden grid",
214
+ "leave-from-class": "grid-rows-[1fr]",
215
+ "leave-to-class": "grid-rows-[0fr]",
216
216
  css: !_ctx.resetting
217
217
  } : void 0)), {
218
218
  default: withCtx(() => [
@@ -26,6 +26,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
26
26
  autocomplete: { default: "off" },
27
27
  autofocus: { type: Boolean },
28
28
  readonly: { type: Boolean },
29
+ unclickable: { type: Boolean },
29
30
  disabledActions: { type: Boolean },
30
31
  loading: { type: Boolean },
31
32
  spellcheck: { type: Boolean },
@@ -54,7 +55,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
54
55
  const input = ref();
55
56
  const isSecureVisible = ref(false);
56
57
  const updateModelValue = (value) => {
57
- if (props.loading || props.disabled || props.readonly) return;
58
+ if (props.loading || props.disabled || props.readonly || props.unclickable) return;
58
59
  if (props.type === "number") {
59
60
  emit("update:modelValue", typeof value === "string" && value.length ? Number.parseFloat(value) : void 0);
60
61
  } else {
@@ -95,14 +96,14 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
95
96
  updateModelValue(value);
96
97
  };
97
98
  const clearValue = () => {
98
- if (props.disabled || props.readonly) return;
99
+ if (props.disabled || props.readonly || props.unclickable) return;
99
100
  if (typeof props.modelValue === "string") updateModelValue("");
100
101
  else updateModelValue(void 0);
101
102
  input.value?.focus();
102
103
  emit("click:clear");
103
104
  };
104
105
  const focus = () => {
105
- if (props.disabled || props.readonly) return;
106
+ if (props.disabled || props.readonly || props.unclickable) return;
106
107
  input.value?.focus();
107
108
  };
108
109
  const blur = () => {
@@ -208,7 +209,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
208
209
  fn: withCtx(({ id, setFocused, focused }) => [
209
210
  createElementVNode("div", {
210
211
  class: normalizeClass(["relative border border-solid rounded-xl bg-default dark:bg-default-dark transition-colors duration-75 overflow-hidden min-h-11 grid grid-cols-[auto,1fr,auto]", {
211
- "focus-within:border-primary-default dark:focus-within:border-primary-dark": !_ctx.disabled && !_ctx.readonly,
212
+ "focus-within:border-primary-default dark:focus-within:border-primary-dark": !_ctx.disabled && !_ctx.readonly && !_ctx.unclickable,
212
213
  "cursor-text": !_ctx.disabled,
213
214
  "border-negative dark:border-negative-dark": _ctx.errorMessage,
214
215
  "border-gray-300 dark:border-gray-700": !_ctx.disabled,
@@ -250,7 +251,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
250
251
  type: _ctx.type ?? "text",
251
252
  name: _ctx.name,
252
253
  disabled: _ctx.disabled,
253
- readonly: _ctx.readonly,
254
+ readonly: _ctx.readonly || _ctx.unclickable,
254
255
  autocomplete: _ctx.autocomplete,
255
256
  size: _ctx.size || void 0,
256
257
  spellcheck: _ctx.spellcheck ? "true" : "false",
@@ -284,7 +285,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
284
285
  loading: _ctx.loading,
285
286
  "allow-clear": _ctx.allowClear && _ctx.modelValue !== "",
286
287
  disabled: _ctx.disabled || _ctx.disabledActions,
287
- readonly: _ctx.readonly,
288
+ readonly: _ctx.readonly || _ctx.unclickable,
288
289
  "text-secure": _ctx.textSecure,
289
290
  "is-secure-visible": isSecureVisible.value,
290
291
  "allow-paste": _ctx.allowPaste,
@@ -26,6 +26,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
26
26
  autocomplete: {},
27
27
  autofocus: { type: Boolean },
28
28
  readonly: { type: Boolean },
29
+ unclickable: { type: Boolean },
29
30
  disabledActions: { type: Boolean },
30
31
  loading: { type: Boolean },
31
32
  spellcheck: { type: Boolean },
@@ -24,6 +24,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
24
24
  autocomplete: {},
25
25
  autofocus: { type: Boolean },
26
26
  readonly: { type: Boolean },
27
+ unclickable: { type: Boolean },
27
28
  disabledActions: { type: Boolean },
28
29
  loading: { type: Boolean },
29
30
  spellcheck: { type: Boolean },
@@ -29,6 +29,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
29
29
  autocomplete: {},
30
30
  autofocus: { type: Boolean },
31
31
  readonly: { type: Boolean },
32
+ unclickable: { type: Boolean },
32
33
  disabledActions: { type: Boolean },
33
34
  loading: { type: Boolean },
34
35
  spellcheck: { type: Boolean },
@@ -25,6 +25,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
25
25
  autocomplete: {},
26
26
  autofocus: { type: Boolean },
27
27
  readonly: { type: Boolean },
28
+ unclickable: { type: Boolean },
28
29
  disabledActions: { type: Boolean },
29
30
  loading: { type: Boolean },
30
31
  spellcheck: { type: Boolean },
@@ -111,7 +112,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
111
112
  }, {
112
113
  ...props,
113
114
  title: unclickable ? _ctx.mobileTitle ?? _ctx.title : _ctx.title,
114
- readonly: _ctx.readonly || unclickable,
115
+ unclickable,
115
116
  description: void 0
116
117
  }, {
117
118
  class: {
@@ -14,6 +14,7 @@ export interface InputProps<Type extends InputType> extends Omit<FieldWrapperPro
14
14
  autocomplete?: 'off' | string;
15
15
  autofocus?: boolean;
16
16
  readonly?: boolean;
17
+ unclickable?: boolean;
17
18
  disabledActions?: boolean;
18
19
  loading?: boolean;
19
20
  spellcheck?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/Input/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,iCAAiC,CAAA;AACtE,OAAO,KAAK,EAAC,SAAS,EAAC,MAAM,KAAK,CAAA;AAClC,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,uBAAuB,CAAA;AAE5D,MAAM,WAAW,UAAU,CAAC,IAAI,SAAS,SAAS,CAAE,SAAQ,IAAI,CAAC,iBAAiB,EAAE,YAAY,CAAC;IAC/F,UAAU,CAAC,EAAE,CAAC,IAAI,SAAS,QAAQ,GAAG,MAAM,GAAG,MAAM,CAAC,GAAG,SAAS,CAAA;IAClE,IAAI,CAAC,EAAE,IAAI,CAAA;IAEX,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,MAAM,CAAC,EAAE,OAAO,CAAA;IAEhB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,IAAI,CAAC,EAAE,YAAY,CAAA;IACnB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,SAAS,CAAC,EAAE,MAAM,CAAA;IAElB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,YAAY,CAAC,EAAE,KAAK,GAAG,MAAM,CAAA;IAC7B,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,OAAO,CAAC,EAAE,OAAO,CAAA;IAEjB,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,qBAAqB,CAAC,EAAE,OA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B,SAAS,CAAC,EAAE,OAAO,CAAA;CACpB;AAED,MAAM,WAAW,eAAe,CAAC,IAAI,SAAS,SAAS,CAAE,SAAQ,UAAU,CAAC,IAAI,CAAC;IAC/E,QAAQ,CAAC,EAAE,UAAU,GAAG,UAAU,EAAE,CAAA;CACrC;AAED,MAAM,WAAW,iBAAiB,CAAC,IAAI,SAAS,SAAS,CAAE,SAAQ,UAAU,CAAC,IAAI,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,iBAAiB,EAAE,QAAQ,GAAG,aAAa,GAAG,YAAY,CAAC,CAAC;IAC5J,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB;AAED,MAAM,WAAW,iBAAiB,CAAC,IAAI,SAAS,SAAS,EAAE,MAAM,CAAE,SAAQ,iBAAiB,CAAC,IAAI,CAAC;IAChG,OAAO,EAAE,MAAM,EAAE,CAAA;IACjB,WAAW,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,QAAQ,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAC,CAAC,YAAY,CAAC,CAAA;IAChF,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,eAAe,CAAC,EAAE,SAAS,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;QAAC,KAAK,CAAC,EAAE,OAAO,CAAA;KAAC,CAAC,CAAA;CACnF;AAED,MAAM,WAAW,cAAe,SAAQ,IAAI,CAAC,iBAAiB,CAAC,MAAM,CAAC,EAAE,YAAY,CAAC;IACnF,UAAU,CAAC,EAAE,IAAI,GAAG,SAAS,CAAA;IAC7B,OAAO,CAAC,EAAE,IAAI,CAAA;IACd,OAAO,CAAC,EAAE,IAAI,CAAA;CACf"}
@@ -1,19 +1,23 @@
1
- import { BulkComponent, ListField, MenuComponent } from './types';
1
+ import { BulkComponent, FieldComponent, ListField, MenuComponent } from './types';
2
2
  declare const _default: <Data extends DefaultData, QueryParams>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
3
3
  props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
4
4
  readonly "onUpdate:header-padding"?: ((value: number) => any) | undefined;
5
5
  } & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onUpdate:header-padding"> & {
6
6
  count?: number;
7
7
  fields: ListField<Data, QueryParams>[];
8
+ expansion?: FieldComponent<Data>;
8
9
  useQueryFn: UseQueryPaginated<Data, QueryParams>;
9
10
  queryParams: QueryParams;
10
11
  bulkDisableMessage?: string;
11
12
  selectionTitle: string;
12
13
  bulk?: BulkComponent<QueryParams>[];
14
+ bulkMore?: BulkComponent<QueryParams>[];
13
15
  menu: MenuComponent<Data>[];
14
16
  readonlyGetter?: (item: Data) => boolean;
15
17
  cardClass?: string;
16
18
  selectAllTextGetter: (isUnselect: boolean, count: number) => string;
19
+ hasBorder?: boolean;
20
+ moreBottom?: boolean;
17
21
  }> & import('vue').PublicProps;
18
22
  expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
19
23
  attrs: any;
@@ -1 +1 @@
1
- {"version":3,"file":"WList.vue.d.ts","sourceRoot":"","sources":["../../../src/components/List/WList.vue"],"names":[],"mappings":"AA4MA,OAAO,KAAK,EAAC,aAAa,EAAE,SAAS,EAAE,aAAa,EAAC,MAAM,SAAS,CAAA;yBAOnD,IAAI,SAAS,WAAW,EAAE,WAAW,eACxC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,cAClD,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,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AW,CAAC,CAAC,CAAC,QAAQ,CAAC;WA2hBxD,mBAAmB,CAAC;;;gBAnhBpB,MAAM;gBACN,SAAS,CAAC,IAAI,EAAE,WAAW,CAAC,EAAE;oBAC1B,cAAc,CAAC,IAAI,CAAC;oBACpB,iBAAiB,CAAC,IAAI,EAAE,WAAW,CAAC;qBACnC,WAAW;6BACH,MAAM;wBACX,MAAM;eACf,aAAa,CAAC,WAAW,CAAC,EAAE;mBACxB,aAAa,CAAC,WAAW,CAAC,EAAE;cACjC,aAAa,CAAC,IAAI,CAAC,EAAE;yBACV,CAAC,IAAI,EAAE,IAAI,KAAK,OAAO;oBAC5B,MAAM;6BACG,CAAC,UAAU,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,KAAK,MAAM;oBACvD,OAAO;qBACN,OAAO;KAqgBiE,CAAC,4BAA2B;oBAChG,OAAO,KAAK,EAAE,gBAAgB,CAAC,EAAE,CAAC,GAAG,IAAI;WAClD,GAAG;;cAlgBP,uBAAuB,SAAS,MAAM,KAAG,IAAI;;;;YAugBP,OAAO,CAAC,OAAO,WAAW,CAAC;;AAriBvE,wBAqiB4E;AAC5E,KAAK,mBAAmB,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
@@ -1,4 +1,4 @@
1
- import { defineComponent, ref, computed, openBlock, createBlock, unref, withCtx, createElementBlock, Fragment, renderList, resolveDynamicComponent, normalizeClass, createCommentVNode, createVNode } from 'vue';
1
+ import { defineComponent, ref, computed, openBlock, createBlock, unref, withCtx, createSlots, createElementBlock, Fragment, renderList, resolveDynamicComponent, normalizeClass, createCommentVNode, createVNode } from 'vue';
2
2
  import _sfc_main$1 from '../InfiniteList/WInfiniteList.vue.js';
3
3
  import { getIsMobile } from '../../utils/mobile.js';
4
4
  import { useSelected, getPosition } from '../../utils/useSelected.js';
@@ -14,15 +14,19 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
14
14
  props: {
15
15
  count: {},
16
16
  fields: {},
17
+ expansion: {},
17
18
  useQueryFn: {},
18
19
  queryParams: {},
19
20
  bulkDisableMessage: {},
20
21
  selectionTitle: {},
21
22
  bulk: {},
23
+ bulkMore: {},
22
24
  menu: {},
23
25
  readonlyGetter: { type: Function },
24
26
  cardClass: {},
25
- selectAllTextGetter: { type: Function }
27
+ selectAllTextGetter: { type: Function },
28
+ hasBorder: { type: Boolean },
29
+ moreBottom: { type: Boolean }
26
30
  },
27
31
  emits: ["update:header-padding"],
28
32
  setup(__props) {
@@ -78,8 +82,6 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
78
82
  "skeleton-length": _ctx.count ?? listCount.value,
79
83
  "header-margin": unref(isMobile) ? 0 : 24,
80
84
  "hide-page-title": "",
81
- transition: "",
82
- "page-class": "grid sm:gap-4",
83
85
  "allow-select": allowSelect.value,
84
86
  "allow-select-range": "",
85
87
  selected: unref(selected),
@@ -90,16 +92,16 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
90
92
  onSelect: unref(setSelected),
91
93
  onSelectReverse: unref(setSelectedReverse),
92
94
  onSelectRange: unref(setSelectedRange),
93
- "onUpdate:headerPadding": _cache[3] || (_cache[3] = ($event) => _ctx.$emit("update:header-padding", $event)),
94
- "onUpdate:count": _cache[4] || (_cache[4] = ($event) => listCount.value = $event)
95
+ "onUpdate:headerPadding": _cache[4] || (_cache[4] = ($event) => _ctx.$emit("update:header-padding", $event)),
96
+ "onUpdate:count": _cache[5] || (_cache[5] = ($event) => listCount.value = $event)
95
97
  }, {
96
98
  header: withCtx(({ selectAllValue }) => [
97
99
  allowSelect.value ? (openBlock(), createBlock(_sfc_main$2, {
98
100
  key: 0,
99
101
  title: _ctx.selectionTitle,
100
102
  "disable-message": _ctx.bulkDisableMessage,
101
- "onUpdate:selectionCount": _cache[1] || (_cache[1] = ($event) => selectionCount.value = $event)
102
- }, {
103
+ "onUpdate:selectionCount": _cache[2] || (_cache[2] = ($event) => selectionCount.value = $event)
104
+ }, createSlots({
103
105
  default: withCtx(({ disableMessage, cssClass }) => [
104
106
  (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.bulk, (item, index) => {
105
107
  return openBlock(), createBlock(resolveDynamicComponent(item), {
@@ -112,8 +114,25 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
112
114
  }, null, 40, ["selection-count", "disable-message", "class"]);
113
115
  }), 128))
114
116
  ]),
115
- _: 1
116
- }, 8, ["title", "disable-message"])) : createCommentVNode("", true),
117
+ _: 2
118
+ }, [
119
+ _ctx.bulkMore ? {
120
+ name: "more",
121
+ fn: withCtx((scope) => [
122
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.bulkMore, (item, index) => {
123
+ return openBlock(), createBlock(resolveDynamicComponent(item), {
124
+ key: index,
125
+ "selection-count": selectionCount.value,
126
+ "query-params-getter": getQueryParamsBulk,
127
+ "disable-message": scope?.disableMessage,
128
+ class: normalizeClass(scope?.cssClass),
129
+ "onClear:selected": _cache[1] || (_cache[1] = ($event) => unref(setSelected)([]))
130
+ }, null, 40, ["selection-count", "disable-message", "class"]);
131
+ }), 128))
132
+ ]),
133
+ key: "0"
134
+ } : void 0
135
+ ]), 1032, ["title", "disable-message"])) : createCommentVNode("", true),
117
136
  !unref(isMobile) ? (openBlock(), createBlock(_sfc_main$3, {
118
137
  key: 1,
119
138
  class: "sm-not:hidden",
@@ -122,18 +141,20 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
122
141
  "tooltip-text": _ctx.selectAllTextGetter(selectAllValue !== true, _ctx.count ?? listCount.value),
123
142
  count: _ctx.count ?? listCount.value,
124
143
  selection: selectAllValue,
125
- "onToggle:selection": _cache[2] || (_cache[2] = ($event) => $event ? unref(setSelectedReverse)([]) : unref(setSelected)([]))
144
+ "onToggle:selection": _cache[3] || (_cache[3] = ($event) => $event ? unref(setSelectedReverse)([]) : unref(setSelected)([]))
126
145
  }, {
127
146
  default: withCtx(() => [
128
147
  (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.fields, (field, index) => {
129
- return openBlock(), createBlock(_sfc_main$4, {
130
- key: index,
131
- title: typeof field.title === "string" ? field.title : field.title(_ctx.queryParams),
132
- field: field.field,
133
- class: normalizeClass([field.cssClass, index === _ctx.fields.length - 1 ? "z-[1]" : void 0]),
134
- ordering: ordering.value,
135
- disabled: !field.field
136
- }, null, 8, ["title", "field", "class", "ordering", "disabled"]);
148
+ return openBlock(), createElementBlock(Fragment, { key: index }, [
149
+ field.visibleGetter?.(_ctx.queryParams) ?? true ? (openBlock(), createBlock(_sfc_main$4, {
150
+ key: 0,
151
+ title: typeof field.title === "string" ? field.title : field.title(_ctx.queryParams),
152
+ field: typeof field.field === "string" ? field.field : field.field?.(_ctx.queryParams),
153
+ class: normalizeClass([field.cssClass, index === _ctx.fields.length - 1 ? "z-[1]" : void 0]),
154
+ ordering: ordering.value,
155
+ disabled: !field.field
156
+ }, null, 8, ["title", "field", "class", "ordering", "disabled"])) : createCommentVNode("", true)
157
+ ], 64);
137
158
  }), 128))
138
159
  ]),
139
160
  _: 2
@@ -143,8 +164,36 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
143
164
  createVNode(_sfc_main$5, {
144
165
  disabled: skeleton,
145
166
  mobile: unref(isMobile),
146
- class: normalizeClass(_ctx.cardClass)
147
- }, {
167
+ "card-class": _ctx.cardClass,
168
+ "has-border": _ctx.hasBorder,
169
+ "more-bottom": _ctx.moreBottom,
170
+ "allow-open": _ctx.fields.some((item2) => item2.allowOpen) && !skeleton
171
+ }, createSlots({
172
+ default: withCtx(({ toggle, isOpen }) => [
173
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.fields, (field, index) => {
174
+ return openBlock(), createElementBlock(Fragment, { key: index }, [
175
+ field.visibleGetter?.(_ctx.queryParams) ?? true ? (openBlock(), createBlock(resolveDynamicComponent(field.component), {
176
+ key: 0,
177
+ item,
178
+ readonly: _ctx.readonlyGetter?.(item),
179
+ skeleton,
180
+ mobile: unref(isMobile),
181
+ class: normalizeClass({
182
+ [field.cssClass ?? ""]: true,
183
+ "cursor-pointer w-ripple w-ripple-hover w-ripple-has w-ripple-opacity-[0.04]": field.allowOpen && !skeleton,
184
+ "sm:border-y border-gray-300 dark:border-gray-700": _ctx.hasBorder,
185
+ "sm:border-b-[transparent] sm:dark:border-b-[transparent]": _ctx.hasBorder && isOpen
186
+ }),
187
+ "onUpdate:item": setter,
188
+ "onDelete:item": ($event) => {
189
+ setter();
190
+ refetch();
191
+ },
192
+ onClick: ($event) => field.allowOpen && !skeleton && toggle()
193
+ }, null, 40, ["item", "readonly", "skeleton", "mobile", "class", "onUpdate:item", "onDelete:item", "onClick"])) : createCommentVNode("", true)
194
+ ], 64);
195
+ }), 128))
196
+ ]),
148
197
  more: withCtx(() => [
149
198
  (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.menu, (menuItem, menuIndex) => {
150
199
  return openBlock(), createBlock(resolveDynamicComponent(menuItem), {
@@ -159,24 +208,26 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
159
208
  }, null, 40, ["item", "readonly", "onUpdate:item", "onDelete:item"]);
160
209
  }), 128))
161
210
  ]),
162
- default: withCtx(() => [
163
- (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.fields, (field, index) => {
164
- return openBlock(), createBlock(resolveDynamicComponent(field.component), {
165
- key: index,
211
+ _: 2
212
+ }, [
213
+ _ctx.expansion ? {
214
+ name: "expansion",
215
+ fn: withCtx(() => [
216
+ (openBlock(), createBlock(resolveDynamicComponent(_ctx.expansion), {
166
217
  item,
167
218
  readonly: _ctx.readonlyGetter?.(item),
168
- class: normalizeClass(field.cssClass),
169
219
  skeleton,
220
+ mobile: unref(isMobile),
170
221
  "onUpdate:item": setter,
171
222
  "onDelete:item": ($event) => {
172
223
  setter();
173
224
  refetch();
174
225
  }
175
- }, null, 40, ["item", "readonly", "class", "skeleton", "onUpdate:item", "onDelete:item"]);
176
- }), 128))
177
- ]),
178
- _: 2
179
- }, 1032, ["disabled", "mobile", "class"])
226
+ }, null, 40, ["item", "readonly", "skeleton", "mobile", "onUpdate:item", "onDelete:item"]))
227
+ ]),
228
+ key: "0"
229
+ } : void 0
230
+ ]), 1032, ["disabled", "mobile", "card-class", "has-border", "more-bottom", "allow-open"])
180
231
  ]),
181
232
  _: 1
182
233
  }, 8, ["use-query-fn", "query-params", "skeleton-length", "header-margin", "allow-select", "selected", "reverse", "selected-range", "count", "onSelect", "onSelectReverse", "onSelectRange"]);
@@ -1,9 +1,11 @@
1
1
  declare function __VLS_template(): {
2
2
  slots: {
3
3
  default?(_: {
4
- toggle: ((value: boolean) => void) | undefined;
4
+ toggle: () => void;
5
+ isOpen: boolean;
5
6
  }): any;
6
7
  more?(_: {}): any;
8
+ expansion?(_: {}): any;
7
9
  };
8
10
  refs: {};
9
11
  attrs: Partial<{}>;
@@ -15,6 +17,9 @@ declare const __VLS_component: import('vue').DefineComponent<{
15
17
  mobile?: boolean;
16
18
  moreBottom?: boolean;
17
19
  alignTop?: boolean;
20
+ hasBorder?: boolean;
21
+ cardClass?: string;
22
+ allowOpen?: boolean;
18
23
  }, {
19
24
  updateSelected: ((value: boolean) => void) | undefined;
20
25
  }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
@@ -26,6 +31,9 @@ declare const __VLS_component: import('vue').DefineComponent<{
26
31
  mobile?: boolean;
27
32
  moreBottom?: boolean;
28
33
  alignTop?: boolean;
34
+ hasBorder?: boolean;
35
+ cardClass?: string;
36
+ allowOpen?: boolean;
29
37
  }> & Readonly<{
30
38
  "onUpdate:selected"?: ((value: boolean) => any) | undefined;
31
39
  "onUpdate:selected-hover"?: ((value: boolean) => any) | undefined;
@@ -1 +1 @@
1
- {"version":3,"file":"WListCard.vue.d.ts","sourceRoot":"","sources":["../../../src/components/List/WListCard.vue"],"names":[],"mappings":"AA0LA,iBAAS,cAAc;;;;YA0LO,GAAG;sBACN,GAAG;;;WAShB,OAAO,IAA6B;EAEjD;AA0BD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;eAzRR,OAAO;eACP,OAAO;aACT,OAAO;iBACH,OAAO;eACT,OAAO;;;;;;;eAJP,OAAO;eACP,OAAO;aACT,OAAO;iBACH,OAAO;eACT,OAAO;;;;kFAgSlB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAWpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"WListCard.vue.d.ts","sourceRoot":"","sources":["../../../src/components/List/WListCard.vue"],"names":[],"mappings":"AAqQA,iBAAS,cAAc;;;;;YAuSO,GAAG;sBACN,GAAG;2BACE,GAAG;;;WASrB,OAAO,IAA6B;EAEjD;AA4BD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;eAlZR,OAAO;eACP,OAAO;aACT,OAAO;iBACH,OAAO;eACT,OAAO;gBACN,OAAO;gBACP,MAAM;gBACN,OAAO;;;;;;;eAPR,OAAO;eACP,OAAO;aACT,OAAO;iBACH,OAAO;eACT,OAAO;gBACN,OAAO;gBACP,MAAM;gBACN,OAAO;;;;kFAsZnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAWpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -1,4 +1,4 @@
1
- import { defineComponent, inject, watch, openBlock, createElementBlock, createVNode, Transition, withCtx, unref, createCommentVNode, createBlock, normalizeClass, renderSlot, markRaw } from 'vue';
1
+ import { defineComponent, ref, inject, watch, openBlock, createElementBlock, Fragment, createElementVNode, normalizeClass, createVNode, Transition, withCtx, unref, createCommentVNode, createBlock, renderSlot, normalizeProps, guardReactiveProps, markRaw } from 'vue';
2
2
  import _sfc_main$1 from '../Checkbox/WCheckbox.vue.js';
3
3
  import _sfc_main$2 from '../Button/WButtonMore.vue.js';
4
4
  import _sfc_main$3 from '../Button/WButtonMoreItem.vue.js';
@@ -6,11 +6,14 @@ import IconAddCircle from '../../assets/icons/sax/IconAddCircle.svg.js';
6
6
  import IconMinusCircle from '../../assets/icons/sax/IconMinusCircle.svg.js';
7
7
  import { wInfiniteListSelection, wInfiniteListSelectionItem } from '../InfiniteList/models/injection.js';
8
8
 
9
- const _hoisted_1 = { class: "grid relative w-full sm:flex sm-not:group-even:bg-gray-50 sm-not:dark:group-even:bg-primary-darkest/25 sm-not:pt-2" };
10
- const _hoisted_2 = {
9
+ const _hoisted_1 = {
11
10
  key: 0,
12
11
  class: "bg-primary-default dark:bg-primary-dark w-2 h-full hidden sm-not:block absolute left-0 top-0"
13
12
  };
13
+ const _hoisted_2 = {
14
+ key: 0,
15
+ class: "absolute top-0 -z-[1] left-full h-full w-[calc(var(--actions-bar-width)+var(--inner-margin))] bg-default dark:bg-default-dark sm-not:hidden"
16
+ };
14
17
  const _sfc_main = /* @__PURE__ */ defineComponent({
15
18
  __name: "WListCard",
16
19
  props: {
@@ -18,11 +21,18 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
18
21
  hideMore: { type: Boolean },
19
22
  mobile: { type: Boolean },
20
23
  moreBottom: { type: Boolean },
21
- alignTop: { type: Boolean }
24
+ alignTop: { type: Boolean },
25
+ hasBorder: { type: Boolean },
26
+ cardClass: {},
27
+ allowOpen: { type: Boolean }
22
28
  },
23
29
  emits: ["update:selected", "update:selected-hover"],
24
30
  setup(__props, { expose: __expose, emit: __emit }) {
25
31
  const emit = __emit;
32
+ const isOpen = ref(false);
33
+ const toggle = () => {
34
+ isOpen.value = !isOpen.value;
35
+ };
26
36
  const {
27
37
  allowSelect,
28
38
  allowSelectRange,
@@ -49,54 +59,106 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
49
59
  updateSelected
50
60
  });
51
61
  return (_ctx, _cache) => {
52
- return openBlock(), createElementBlock("div", _hoisted_1, [
53
- createVNode(Transition, {
54
- "enter-active-class": "transition-transform duration-200",
55
- "leave-active-class": "transition-transform duration-200",
56
- "enter-from-class": "-translate-x-2",
57
- "leave-to-class": "-translate-x-2"
58
- }, {
59
- default: withCtx(() => [
60
- _ctx.mobile && unref(selected) ? (openBlock(), createElementBlock("div", _hoisted_2)) : createCommentVNode("", true)
61
- ]),
62
- _: 1
63
- }),
64
- unref(allowSelect) && !_ctx.mobile ? (openBlock(), createBlock(_sfc_main$1, {
65
- key: 0,
66
- "model-value": unref(selectedBetween) ? null : unref(selected) ?? false,
67
- disabled: _ctx.disabled,
68
- "allow-shift": unref(allowSelectRange),
69
- "align-top": _ctx.alignTop,
70
- class: normalizeClass(["sm:w-list-row-item sm-not:hidden", {
71
- "opacity-50": unref(allowSelectHover)
72
- }]),
73
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => unref(allowSelectHover) ? unref(updateSelectedRange)?.() : unref(updateSelected)?.($event)),
74
- "onUpdateShift:modelValue": _cache[1] || (_cache[1] = ($event) => unref(updateSelectedRange)?.()),
75
- onMouseover: _cache[2] || (_cache[2] = ($event) => unref(allowSelectHover) ? unref(updateSelectedRangeHover)?.() : void 0)
76
- }, null, 8, ["model-value", "disabled", "allow-shift", "align-top", "class"])) : createCommentVNode("", true),
77
- renderSlot(_ctx.$slots, "default", { toggle: unref(updateSelected) }),
78
- !_ctx.hideMore ? (openBlock(), createBlock(_sfc_main$2, {
79
- key: 1,
80
- class: normalizeClass(["sm-not:absolute sm-not:right-0 sm-not:-mx--inner-margin sm-not:bottom-0 sm-not:items-start sm:w-list-row-item flex pl-4", {
81
- "sm-not:top-5": !_ctx.moreBottom,
82
- "sm-not:top-12": _ctx.moreBottom,
83
- "items-start pt-2": _ctx.alignTop,
84
- "items-center": !_ctx.alignTop
85
- }]),
86
- disabled: _ctx.disabled
87
- }, {
88
- default: withCtx(() => [
89
- unref(allowSelect) && _ctx.mobile ? (openBlock(), createBlock(_sfc_main$3, {
90
- key: 0,
91
- text: unref(selected) ? "Unselect" : "Select",
92
- icon: unref(selected) ? markRaw(unref(IconMinusCircle)) : markRaw(unref(IconAddCircle)),
93
- onClick: _cache[3] || (_cache[3] = ($event) => unref(updateSelected)?.(!unref(selected)))
94
- }, null, 8, ["text", "icon"])) : createCommentVNode("", true),
95
- renderSlot(_ctx.$slots, "more")
96
- ]),
97
- _: 3
98
- }, 8, ["class", "disabled"])) : createCommentVNode("", true)
99
- ]);
62
+ return openBlock(), createElementBlock(Fragment, null, [
63
+ createElementVNode("div", {
64
+ class: normalizeClass(["relative w-full grid sm:flex isolate sm:mt-4 first:mt-0 sm-not:group-even:bg-gray-50 sm-not:dark:group-even:bg-primary-darkest/25 sm-not:pt-2 sm-not:-px--inner-margin", {
65
+ [_ctx.cardClass ?? ""]: true,
66
+ "w-ripple-trigger-has": _ctx.allowOpen
67
+ }])
68
+ }, [
69
+ createVNode(Transition, {
70
+ "enter-active-class": "transition-transform duration-200",
71
+ "leave-active-class": "transition-transform duration-200",
72
+ "enter-from-class": "-translate-x-2",
73
+ "leave-to-class": "-translate-x-2"
74
+ }, {
75
+ default: withCtx(() => [
76
+ _ctx.mobile && unref(selected) ? (openBlock(), createElementBlock("div", _hoisted_1)) : createCommentVNode("", true)
77
+ ]),
78
+ _: 1
79
+ }),
80
+ !_ctx.mobile ? (openBlock(), createElementBlock("div", {
81
+ key: 0,
82
+ class: normalizeClass(["sticky z-[1] left-inner sm-not:hidden bg-default dark:bg-default-dark", {
83
+ "width-16": unref(allowSelect),
84
+ "width-4": !unref(allowSelect)
85
+ }])
86
+ }, [
87
+ _cache[4] || (_cache[4] = createElementVNode("div", { class: "absolute top-0 -z-[1] right-full h-full w-[calc(var(--nav-bar-width)+var(--inner-margin))] bg-default dark:bg-default-dark" }, null, -1)),
88
+ createElementVNode("div", {
89
+ class: normalizeClass(["h-full", {
90
+ "sm:border sm:border-r-0 border-gray-300 dark:border-gray-700 sm:rounded-tl-3xl": _ctx.hasBorder,
91
+ "sm:rounded-bl-3xl": _ctx.hasBorder && !isOpen.value,
92
+ "sm:border-b-[transparent] sm:dark:border-b-[transparent]": _ctx.hasBorder && isOpen.value,
93
+ "w-ripple-has-only w-ripple-hover w-ripple-opacity-[0.04]": _ctx.allowOpen
94
+ }])
95
+ }, [
96
+ unref(allowSelect) ? (openBlock(), createBlock(_sfc_main$1, {
97
+ key: 0,
98
+ "model-value": unref(selectedBetween) ? null : unref(selected) ?? false,
99
+ disabled: _ctx.disabled,
100
+ "allow-shift": unref(allowSelectRange),
101
+ "align-top": _ctx.alignTop,
102
+ class: normalizeClass(["px-4 h-full", {
103
+ "opacity-50": unref(allowSelectHover)
104
+ }]),
105
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => unref(allowSelectHover) ? unref(updateSelectedRange)?.() : unref(updateSelected)?.($event)),
106
+ "onUpdateShift:modelValue": _cache[1] || (_cache[1] = ($event) => unref(updateSelectedRange)?.()),
107
+ onMouseover: _cache[2] || (_cache[2] = ($event) => unref(allowSelectHover) ? unref(updateSelectedRangeHover)?.() : void 0)
108
+ }, null, 8, ["model-value", "disabled", "allow-shift", "align-top", "class"])) : createCommentVNode("", true)
109
+ ], 2)
110
+ ], 2)) : createCommentVNode("", true),
111
+ renderSlot(_ctx.$slots, "default", normalizeProps(guardReactiveProps({ toggle, isOpen: isOpen.value }))),
112
+ createElementVNode("div", {
113
+ class: normalizeClass(["sm:sticky sm:z-[1] sm:right-inner sm:bg-default sm:dark:bg-default-dark", {
114
+ "width-14": !_ctx.hideMore,
115
+ "width-4": _ctx.hideMore
116
+ }])
117
+ }, [
118
+ !_ctx.mobile ? (openBlock(), createElementBlock("div", _hoisted_2)) : createCommentVNode("", true),
119
+ createElementVNode("div", {
120
+ class: normalizeClass(["h-full", {
121
+ "sm:border sm:border-l-0 border-gray-300 dark:border-gray-700 sm:rounded-tr-3xl": _ctx.hasBorder,
122
+ "sm:rounded-br-3xl": _ctx.hasBorder && !isOpen.value,
123
+ "sm:border-b-[transparent] sm:dark:border-b-[transparent]": _ctx.hasBorder && isOpen.value,
124
+ "w-ripple-has-only w-ripple-hover w-ripple-opacity-[0.04]": _ctx.allowOpen
125
+ }])
126
+ }, [
127
+ !_ctx.hideMore ? (openBlock(), createBlock(_sfc_main$2, {
128
+ key: 0,
129
+ class: normalizeClass(["sm-not:absolute sm-not:right-0 sm-not:bottom-0 flex px-4 sm:h-full", {
130
+ "sm-not:top-5": !_ctx.moreBottom,
131
+ "sm-not:top-10": _ctx.moreBottom,
132
+ "items-start pt-2": _ctx.alignTop,
133
+ "items-center": !_ctx.alignTop
134
+ }]),
135
+ disabled: _ctx.disabled
136
+ }, {
137
+ default: withCtx(() => [
138
+ unref(allowSelect) && _ctx.mobile ? (openBlock(), createBlock(_sfc_main$3, {
139
+ key: 0,
140
+ text: unref(selected) ? "Unselect" : "Select",
141
+ icon: unref(selected) ? markRaw(unref(IconMinusCircle)) : markRaw(unref(IconAddCircle)),
142
+ onClick: _cache[3] || (_cache[3] = ($event) => unref(updateSelected)?.(!unref(selected)))
143
+ }, null, 8, ["text", "icon"])) : createCommentVNode("", true),
144
+ renderSlot(_ctx.$slots, "more")
145
+ ]),
146
+ _: 3
147
+ }, 8, ["class", "disabled"])) : createCommentVNode("", true)
148
+ ], 2)
149
+ ], 2)
150
+ ], 2),
151
+ _ctx.$slots.expansion ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
152
+ isOpen.value ? (openBlock(), createElementBlock("div", {
153
+ key: 0,
154
+ class: normalizeClass(["sm:sticky sm:w-inner sm:left-inner", {
155
+ "sm:px-5 sm:border sm:border-t-0 border-gray-300 dark:border-gray-700 sm:rounded-b-3xl": _ctx.hasBorder
156
+ }])
157
+ }, [
158
+ renderSlot(_ctx.$slots, "expansion")
159
+ ], 2)) : createCommentVNode("", true)
160
+ ], 64)) : createCommentVNode("", true)
161
+ ], 64);
100
162
  };
101
163
  }
102
164
  });
@@ -1 +1 @@
1
- {"version":3,"file":"WListCardField.vue.d.ts","sourceRoot":"","sources":["../../../src/components/List/WListCardField.vue"],"names":[],"mappings":"AA0DA,iBAAS,cAAc;;yBAkEM,GAAG;uBACL,GAAG;uBACF,GAAG;;;WASjB,OAAO,IAA6B;EAEjD;AAUD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;iBApGN,MAAM,GAAG,MAAM;eACjB,OAAO;;iBADL,MAAM,GAAG,MAAM;eACjB,OAAO;iGAyGlB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAWpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"WListCardField.vue.d.ts","sourceRoot":"","sources":["../../../src/components/List/WListCardField.vue"],"names":[],"mappings":"AAuDA,iBAAS,cAAc;;yBA8DM,GAAG;uBACL,GAAG;uBACF,GAAG;;;WASjB,OAAO,IAA6B;EAEjD;AAUD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;iBAhGN,MAAM,GAAG,MAAM;eACjB,OAAO;;iBADL,MAAM,GAAG,MAAM;eACjB,OAAO;iGAqGlB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAWpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -1,11 +1,10 @@
1
- import { defineComponent, openBlock, createElementBlock, createElementVNode, createBlock, renderSlot, createTextVNode, toDisplayString, createVNode, withCtx } from 'vue';
1
+ import { defineComponent, openBlock, createElementBlock, createBlock, renderSlot, createElementVNode, createTextVNode, toDisplayString, createVNode, withCtx } from 'vue';
2
2
  import WSkeleton from '../Skeleton/WSkeleton.vue.js';
3
3
  import _sfc_main$1 from '../Tooltip/WTooltip.vue.js';
4
4
 
5
- const _hoisted_1 = { class: "flex items-center sm:h-16" };
6
- const _hoisted_2 = { class: "w-full relative" };
7
- const _hoisted_3 = { class: "absolute top-0 w-full truncate" };
8
- const _hoisted_4 = { class: "min-w-[12rem] max-w-xl overflow-hidden" };
5
+ const _hoisted_1 = { class: "grid grid-cols-1 items-center sm:h-16 sm:pr-6" };
6
+ const _hoisted_2 = { class: "truncate" };
7
+ const _hoisted_3 = { class: "min-w-[12rem] max-w-xl overflow-hidden" };
9
8
  const _sfc_main = /* @__PURE__ */ defineComponent({
10
9
  __name: "WListCardField",
11
10
  props: {
@@ -15,27 +14,24 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
15
14
  setup(__props) {
16
15
  return (_ctx, _cache) => {
17
16
  return openBlock(), createElementBlock("div", _hoisted_1, [
18
- createElementVNode("div", _hoisted_2, [
19
- _ctx.skeleton ? (openBlock(), createBlock(WSkeleton, { key: 0 })) : renderSlot(_ctx.$slots, "default", { key: 1 }, () => [
20
- _cache[0] || (_cache[0] = createTextVNode("   ")),
21
- createElementVNode("div", _hoisted_3, [
22
- renderSlot(_ctx.$slots, "inner", {}, () => [
23
- createTextVNode(toDisplayString(_ctx.modelValue), 1)
24
- ]),
25
- createVNode(_sfc_main$1, {
26
- "no-touch": "",
27
- "overflow-only": ""
28
- }, {
29
- default: withCtx(() => [
30
- createElementVNode("div", _hoisted_4, [
31
- renderSlot(_ctx.$slots, "inner", {}, () => [
32
- createTextVNode(toDisplayString(_ctx.modelValue), 1)
33
- ])
17
+ _ctx.skeleton ? (openBlock(), createBlock(WSkeleton, { key: 0 })) : renderSlot(_ctx.$slots, "default", { key: 1 }, () => [
18
+ createElementVNode("div", _hoisted_2, [
19
+ renderSlot(_ctx.$slots, "inner", {}, () => [
20
+ createTextVNode(toDisplayString(_ctx.modelValue), 1)
21
+ ]),
22
+ createVNode(_sfc_main$1, {
23
+ "no-touch": "",
24
+ "overflow-only": ""
25
+ }, {
26
+ default: withCtx(() => [
27
+ createElementVNode("div", _hoisted_3, [
28
+ renderSlot(_ctx.$slots, "inner", {}, () => [
29
+ createTextVNode(toDisplayString(_ctx.modelValue), 1)
34
30
  ])
35
- ]),
36
- _: 3
37
- })
38
- ])
31
+ ])
32
+ ]),
33
+ _: 3
34
+ })
39
35
  ])
40
36
  ])
41
37
  ]);
@@ -1 +1 @@
1
- {"version":3,"file":"WListHeader.vue.d.ts","sourceRoot":"","sources":["../../../src/components/List/WListHeader.vue"],"names":[],"mappings":"AAwEA,iBAAS,cAAc;;yBA4EM,GAAG;;;WASlB,OAAO,IAA6B;EAEjD;AAYD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;kBAzHL,OAAO;eACV,OAAO;eACP,OAAO;YACV,MAAM;gBACF,OAAO,GAAG,IAAI;iBACb,MAAM;;;;kBALL,OAAO;eACV,OAAO;eACP,OAAO;YACV,MAAM;gBACF,OAAO,GAAG,IAAI;iBACb,MAAM;;;kFA6HnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAWpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"WListHeader.vue.d.ts","sourceRoot":"","sources":["../../../src/components/List/WListHeader.vue"],"names":[],"mappings":"AAsFA,iBAAS,cAAc;;yBAsIM,GAAG;;;WASlB,OAAO,IAA6B;EAEjD;AAYD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;kBAnLL,OAAO;eACV,OAAO;eACP,OAAO;YACV,MAAM;gBACF,OAAO,GAAG,IAAI;iBACb,MAAM;;;;kBALL,OAAO;eACV,OAAO;eACP,OAAO;YACV,MAAM;gBACF,OAAO,GAAG,IAAI;iBACb,MAAM;;;kFAuLnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAWpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -1,15 +1,10 @@
1
- import { defineComponent, openBlock, createElementBlock, Fragment, createBlock, createCommentVNode, renderSlot } from 'vue';
1
+ import { defineComponent, openBlock, createElementBlock, createElementVNode, normalizeClass, createBlock, createCommentVNode, renderSlot } from 'vue';
2
2
  import _sfc_main$1 from '../Checkbox/WCheckbox.vue.js';
3
3
 
4
- const _hoisted_1 = { class: "flex text-description font-semibold" };
5
- const _hoisted_2 = {
6
- key: 0,
7
- class: "w-list-header-item width-16"
8
- };
9
- const _hoisted_3 = {
10
- key: 1,
11
- class: "w-list-header-item width-14"
12
- };
4
+ const _hoisted_1 = { class: "flex text-description font-semibold h-12" };
5
+ const _hoisted_2 = { class: "sticky z-[1] left-inner bg-default dark:bg-default-dark" };
6
+ const _hoisted_3 = { class: "bg-primary-light dark:bg-primary-darkest border-y border-solid border-gray-300 dark:border-gray-700 flex flex-1" };
7
+ const _hoisted_4 = { class: "sticky z-[1] right-inner bg-default dark:bg-default-dark" };
13
8
  const _sfc_main = /* @__PURE__ */ defineComponent({
14
9
  __name: "WListHeader",
15
10
  props: {
@@ -24,19 +19,37 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
24
19
  setup(__props) {
25
20
  return (_ctx, _cache) => {
26
21
  return openBlock(), createElementBlock("div", _hoisted_1, [
27
- _ctx.allowSelect ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
28
- _ctx.selection === void 0 || _ctx.count === 0 ? (openBlock(), createElementBlock("div", _hoisted_2)) : (openBlock(), createBlock(_sfc_main$1, {
29
- key: 1,
30
- disabled: _ctx.disabled,
31
- "model-value": _ctx.selection,
32
- "tooltip-text": _ctx.tooltipText,
33
- intermediate: "",
34
- class: "w-list-header-item width-16 justify-end",
35
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.$emit("toggle:selection", $event))
36
- }, null, 8, ["disabled", "model-value", "tooltip-text"]))
37
- ], 64)) : createCommentVNode("", true),
38
- renderSlot(_ctx.$slots, "default"),
39
- !_ctx.hideMore ? (openBlock(), createElementBlock("div", _hoisted_3)) : createCommentVNode("", true)
22
+ createElementVNode("div", _hoisted_2, [
23
+ _cache[1] || (_cache[1] = createElementVNode("div", { class: "absolute top-0 -z-[1] right-full h-full w-[calc(var(--nav-bar-width)+var(--inner-margin))] bg-default dark:bg-default-dark" }, null, -1)),
24
+ createElementVNode("div", {
25
+ class: normalizeClass(["bg-primary-light dark:bg-primary-darkest border-y border-solid border-gray-300 dark:border-gray-700 rounded-l-2xl border-l h-full", {
26
+ "width-16": _ctx.allowSelect,
27
+ "width-4": !_ctx.allowSelect
28
+ }])
29
+ }, [
30
+ _ctx.allowSelect && _ctx.selection !== void 0 && _ctx.count !== 0 ? (openBlock(), createBlock(_sfc_main$1, {
31
+ key: 0,
32
+ disabled: _ctx.disabled,
33
+ "model-value": _ctx.selection,
34
+ "tooltip-text": _ctx.tooltipText,
35
+ intermediate: "",
36
+ class: "w-full h-full justify-end pr-6",
37
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.$emit("toggle:selection", $event))
38
+ }, null, 8, ["disabled", "model-value", "tooltip-text"])) : createCommentVNode("", true)
39
+ ], 2)
40
+ ]),
41
+ createElementVNode("div", _hoisted_3, [
42
+ renderSlot(_ctx.$slots, "default")
43
+ ]),
44
+ createElementVNode("div", _hoisted_4, [
45
+ _cache[2] || (_cache[2] = createElementVNode("div", { class: "absolute top-0 -z-[1] left-full h-full w-[calc(var(--actions-bar-width)+var(--inner-margin))] bg-default dark:bg-default-dark" }, null, -1)),
46
+ createElementVNode("div", {
47
+ class: normalizeClass(["bg-primary-light dark:bg-primary-darkest border-y border-solid border-gray-300 dark:border-gray-700 rounded-r-2xl border-r h-full", {
48
+ "width-14": !_ctx.hideMore,
49
+ "width-4": _ctx.hideMore
50
+ }])
51
+ }, null, 2)
52
+ ])
40
53
  ]);
41
54
  };
42
55
  }
@@ -1 +1 @@
1
- {"version":3,"file":"WListHeaderItem.vue.d.ts","sourceRoot":"","sources":["../../../src/components/List/WListHeaderItem.vue"],"names":[],"mappings":"AAkGA,OAAO,EAAwB,KAAK,SAAS,EAAC,MAAM,eAAe,CAAA;yBAGlD,KAAK,eACR,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,cAClD,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC,iBAC5F,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC;WAyJxD,mBAAmB,CAAC;gBArJpB,MAAM;eACP,KAAK;kBACF,SAAS,CAAC,KAAK,CAAC,EAAE;mBACjB,OAAO;KAkJmE,CAAC,4BAA2B;oBAChG,OAAO,KAAK,EAAE,gBAAgB,CAAC,EAAE,CAAC,GAAG,IAAI;WAClD,GAAG;;yBA1BgB,GAAG;;UA4BvB,EAAE;;;;YAGiC,OAAO,CAAC,OAAO,WAAW,CAAC;;AAnKvE,wBAmK4E;AAC5E,KAAK,mBAAmB,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
1
+ {"version":3,"file":"WListHeaderItem.vue.d.ts","sourceRoot":"","sources":["../../../src/components/List/WListHeaderItem.vue"],"names":[],"mappings":"AAkGA,OAAO,EAAwB,KAAK,SAAS,EAAC,MAAM,eAAe,CAAA;yBAGlD,KAAK,eACR,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,cAClD,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC,iBAC5F,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC;WAwJxD,mBAAmB,CAAC;gBApJpB,MAAM;eACP,KAAK;kBACF,SAAS,CAAC,KAAK,CAAC,EAAE;mBACjB,OAAO;KAiJmE,CAAC,4BAA2B;oBAChG,OAAO,KAAK,EAAE,gBAAgB,CAAC,EAAE,CAAC,GAAG,IAAI;WAClD,GAAG;;yBA1BgB,GAAG;;UA4BvB,EAAE;;;;YAGiC,OAAO,CAAC,OAAO,WAAW,CAAC;;AAlKvE,wBAkK4E;AAC5E,KAAK,mBAAmB,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
@@ -45,7 +45,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
45
45
  };
46
46
  return (_ctx, _cache) => {
47
47
  return openBlock(), createElementBlock("div", {
48
- class: normalizeClass(["w-list-header-item flex gap-2 select-none items-center text-description font-semibold h-11", {
48
+ class: normalizeClass(["pr-6 flex gap-2 select-none items-center text-description font-semibold", {
49
49
  "cursor-pointer": !_ctx.disabled
50
50
  }]),
51
51
  onClick: setOrdering
@@ -3,12 +3,15 @@ export type FieldComponent<Data> = Component<{
3
3
  item: Data;
4
4
  skeleton?: boolean;
5
5
  readonly?: boolean;
6
+ mobile?: boolean;
6
7
  }>;
7
8
  export type ListField<Data, QueryParams = unknown> = {
8
9
  component: Raw<FieldComponent<Data>>;
9
- title: string | ((item: QueryParams) => string);
10
+ title: string | ((params: QueryParams) => string);
10
11
  cssClass?: string;
11
- field?: keyof Data;
12
+ field?: Extract<keyof Data, string> | ((params: QueryParams) => Extract<keyof Data, string>);
13
+ visibleGetter?: (params: QueryParams) => boolean;
14
+ allowOpen?: boolean;
12
15
  };
13
16
  export type MenuComponent<Data> = Component<{
14
17
  item: Data;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/List/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,SAAS,EAAE,GAAG,EAAC,MAAM,KAAK,CAAA;AAEvC,MAAM,MAAM,cAAc,CAAC,IAAI,IAAI,SAAS,CAAC;IAC3C,IAAI,EAAE,IAAI,CAAA;IACV,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,CAAC,CAAA;AAEF,MAAM,MAAM,SAAS,CAAC,IAAI,EAAE,WAAW,GAAG,OAAO,IAAI;IACnD,SAAS,EAAE,GAAG,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,CAAC;IACrC,KAAK,EAAE,MAAM,GAAG,CAAC,CAAC,IAAI,EAAE,WAAW,KAAK,MAAM,CAAC,CAAC;IAChD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,IAAI,CAAC;CACpB,CAAA;AAED,MAAM,MAAM,aAAa,CAAC,IAAI,IAAI,SAAS,CAAC;IAC1C,IAAI,EAAE,IAAI,CAAA;IACV,QA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ACnB,CAAC,CAAA;AAEF,MAAM,MAAM,aAAa,CAAC,WAAW,IAAI,SAAS,CAAC;IACjD,iBAAiB,EAAE,MAAM,WAAW,CAAA;IACpC,cAAc,EAAE,MAAM,CAAA;IACtB,cAAc,CAAC,EAAE,MAAM,CAAA;CACxB,CAAC,CAAA"}
@@ -38,6 +38,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
38
38
  autocomplete: {},
39
39
  autofocus: { type: Boolean },
40
40
  readonly: { type: Boolean },
41
+ unclickable: { type: Boolean },
41
42
  disabledActions: { type: Boolean },
42
43
  loading: { type: Boolean },
43
44
  spellcheck: { type: Boolean },
@@ -36,6 +36,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
36
36
  autocomplete: {},
37
37
  autofocus: { type: Boolean },
38
38
  readonly: { type: Boolean },
39
+ unclickable: { type: Boolean },
39
40
  disabledActions: { type: Boolean },
40
41
  loading: { type: Boolean },
41
42
  spellcheck: { type: Boolean },
@@ -34,6 +34,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
34
34
  autocomplete: {},
35
35
  autofocus: { type: Boolean },
36
36
  readonly: { type: Boolean },
37
+ unclickable: { type: Boolean },
37
38
  disabledActions: { type: Boolean },
38
39
  loading: { type: Boolean },
39
40
  spellcheck: { type: Boolean },
@@ -29,6 +29,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
29
29
  autocomplete: {},
30
30
  autofocus: { type: Boolean },
31
31
  readonly: { type: Boolean },
32
+ unclickable: { type: Boolean },
32
33
  disabledActions: { type: Boolean },
33
34
  loading: { type: Boolean },
34
35
  spellcheck: { type: Boolean },
@@ -29,6 +29,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
29
29
  autocomplete: {},
30
30
  autofocus: { type: Boolean },
31
31
  readonly: { type: Boolean },
32
+ unclickable: { type: Boolean },
32
33
  disabledActions: { type: Boolean },
33
34
  loading: { type: Boolean },
34
35
  spellcheck: { type: Boolean },
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "type": "git",
5
5
  "url": "https://github.com/rsmple/eco-vue-js.git"
6
6
  },
7
- "version": "0.8.18",
7
+ "version": "0.8.19",
8
8
  "scripts": {
9
9
  "dev": "vite",
10
10
  "build": "run-p type-check build-only",
@@ -91,6 +91,27 @@ module.exports = plugin(function ({matchUtilities, addVariant, addUtilities, add
91
91
  },
92
92
  )
93
93
 
94
+ addUtilities({
95
+ '.max-w-inner': {
96
+ 'max-width': 'calc(100vw - var(--actions-bar-width) - var(--nav-bar-width) - var(--inner-margin) - var(--inner-margin) - var(--scroll-bar-width))',
97
+ },
98
+ '.max-w-inner-no-actions': {
99
+ 'max-width': 'calc(100vw - var(--nav-bar-width) - var(--inner-margin) - var(--inner-margin) - var(--scroll-bar-width))',
100
+ },
101
+ '.w-inner': {
102
+ 'width': 'calc(100vw - var(--actions-bar-width) - var(--nav-bar-width) - var(--inner-margin) - var(--inner-margin) - var(--scroll-bar-width))',
103
+ },
104
+ '.min-w-inner': {
105
+ 'min-width': 'calc(100vw - var(--actions-bar-width) - var(--nav-bar-width) - var(--inner-margin) - var(--inner-margin) - var(--scroll-bar-width))',
106
+ },
107
+ '.left-inner': {
108
+ 'left': 'calc(var(--nav-bar-width) + var(--inner-margin))',
109
+ },
110
+ '.right-inner': {
111
+ 'right': 'calc(var(--actions-bar-width) + var(--inner-margin))',
112
+ },
113
+ })
114
+
94
115
  addVariant('supports-backdrop', '@supports ((-webkit-backdrop-filter: none) or (backdrop-filter: none))')
95
116
  addVariant('supports-overlay', '@supports (overflow: overlay)')
96
117
  addVariant('supports-overlay-not', '@supports (not (overflow: overlay))')
@@ -266,7 +287,7 @@ module.exports = plugin(function ({matchUtilities, addVariant, addUtilities, add
266
287
 
267
288
  addUtilities({
268
289
  '.w-ripple': {
269
- '&::before': {
290
+ '&::before, &-has-only::before': {
270
291
  'content': '""',
271
292
  'position': 'absolute',
272
293
  'top': '0',
@@ -294,11 +315,23 @@ module.exports = plugin(function ({matchUtilities, addVariant, addUtilities, add
294
315
  },
295
316
  },
296
317
 
318
+ '.w-ripple-trigger-has:has(.w-ripple-has:active)': {
319
+ '.w-ripple-has-only::before, &.w-ripple-has-only::before': {
320
+ 'opacity': 'calc(var(--w-ripple-opacity, 0.10) * 2)',
321
+ },
322
+ },
323
+
297
324
  '.w-ripple-hover:not(:active):hover, .w-ripple-trigger:not(:active):hover .w-ripple-hover, .w-ripple-hover:not(:active):focus, .w-ripple-trigger:not(:active):focus .w-ripple-hover': {
298
325
  '& .w-ripple:not(:active)::before, &.w-ripple::before': {
299
326
  'opacity': 'var(--w-ripple-opacity, 0.10)',
300
327
  },
301
328
  },
329
+
330
+ '.w-ripple-trigger-has:has(.w-ripple-has:not(:active):hover) .w-ripple-hover, .w-ripple-trigger-has:has(.w-ripple-has:not(:active):focus) .w-ripple-hover': {
331
+ '& .w-ripple-has-only:not(:active)::before, &.w-ripple-has-only::before': {
332
+ 'opacity': 'var(--w-ripple-opacity, 0.10)',
333
+ },
334
+ },
302
335
  })
303
336
 
304
337
  addUtilities({
@@ -386,39 +419,6 @@ module.exports = plugin(function ({matchUtilities, addVariant, addUtilities, add
386
419
  'padding-right': '0.75rem',
387
420
  },
388
421
 
389
- '.w-list-row-item, .w-list-header-item': {
390
- 'padding-right': '1.5rem',
391
- '&:first-child, &.first-item': {
392
- 'padding-left': '1rem',
393
- },
394
- '&:last-child': {
395
- 'padding-right': '1rem',
396
- },
397
- },
398
-
399
- '.w-list-header-item': {
400
- 'height': '3rem',
401
- 'border-top-width': '1px',
402
- 'border-bottom-width': '1px',
403
- 'border-style': 'solid',
404
- 'background-color': theme('colors.primary.light'),
405
- 'border-color': theme('colors.gray.300'),
406
- '.dark &': {
407
- 'background-color': theme('colors.primary.darkest'),
408
- 'border-color': theme('colors.gray.700'),
409
- },
410
- '&:first-child': {
411
- 'border-left-width': '1px',
412
- 'border-top-left-radius': '1rem',
413
- 'border-bottom-left-radius': '1rem',
414
- },
415
- '&:last-child': {
416
- 'border-right-width': '1px',
417
- 'border-top-right-radius': '1rem',
418
- 'border-bottom-right-radius': '1rem',
419
- },
420
- },
421
-
422
422
  '.w-skeleton': {
423
423
  'position': 'relative',
424
424
  'width': 'var(--skeleton-width,70%)',