@simsustech/quasar-components 0.11.13 → 0.11.15

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/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @simsustech/quasar-components
2
2
 
3
+ ## 0.11.15
4
+
5
+ ### Patch Changes
6
+
7
+ - 138a828: fix(components): fix CronScheduleInput style
8
+
9
+ ## 0.11.14
10
+
11
+ ### Patch Changes
12
+
13
+ - 7bc307d: fix(components): fix localeSelect selectedItems slot
14
+
3
15
  ## 0.11.13
4
16
 
5
17
  ### Patch Changes
@@ -502,37 +502,21 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
502
502
  return (_ctx, _cache) => {
503
503
  const _component_q_icon = QIcon;
504
504
  const _component_q_item_section = QItemSection;
505
- const _component_q_item = QItem;
506
505
  const _component_q_item_label = QItemLabel;
506
+ const _component_q_item = QItem;
507
507
  return openBlock(), createBlock(unref(QSelect), mergeProps(unref(attrs), {
508
508
  options: languageOptions.value,
509
509
  "model-value": unref(modelValue),
510
510
  filled: false,
511
- borderless: "",
512
511
  "emit-value": "",
513
512
  "map-options": ""
514
513
  }), {
515
514
  "selected-item": withCtx((scope) => [
516
515
  scope.opt ? (openBlock(), createElementBlock("div", _hoisted_1, [
517
- createVNode(_component_q_item, null, {
518
- default: withCtx(() => [
519
- createVNode(_component_q_item_section, { avatar: "" }, {
520
- default: withCtx(() => [
521
- createVNode(_component_q_icon, {
522
- name: scope.opt.icon
523
- }, null, 8, ["name"])
524
- ]),
525
- _: 2
526
- }, 1024),
527
- createVNode(_component_q_item_section, { label: "" }, {
528
- default: withCtx(() => [
529
- createTextVNode(toDisplayString(scope.opt.label), 1)
530
- ]),
531
- _: 2
532
- }, 1024)
533
- ]),
534
- _: 2
535
- }, 1024)
516
+ createVNode(_component_q_icon, {
517
+ name: scope.opt.icon
518
+ }, null, 8, ["name"]),
519
+ createTextVNode(" " + toDisplayString(scope.opt.label), 1)
536
520
  ])) : createCommentVNode("", true)
537
521
  ]),
538
522
  option: withCtx((scope) => [
package/dist/form.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, useAttrs, withAsyncContext, watch, ref, createBlock, openBlock, unref, mergeProps, normalizeProps, guardReactiveProps, withCtx, createVNode, createTextVNode, toDisplayString, toRefs, computed, useSlots, createCommentVNode, renderSlot, createSlots, renderList, resolveDirective, createElementVNode, withDirectives, createElementBlock, Fragment, resolveDynamicComponent } from "vue";
2
2
  import { useQuasar, QSelect, QItem, QItemSection, QItemLabel, QInput, QField, QIcon, QTooltip, QPopupProxy, QDate, QBtn, QEditor } from "quasar";
3
- import { u as useLang, l as loadLang } from "./LocaleSelect.vue_vue_type_script_setup_true_lang-Du4fNbTV.js";
4
- import { _ } from "./LocaleSelect.vue_vue_type_script_setup_true_lang-Du4fNbTV.js";
3
+ import { u as useLang, l as loadLang } from "./LocaleSelect.vue_vue_type_script_setup_true_lang-DmbnGyqQ.js";
4
+ import { _ } from "./LocaleSelect.vue_vue_type_script_setup_true_lang-DmbnGyqQ.js";
5
5
  const _sfc_main$d = /* @__PURE__ */ defineComponent({
6
6
  __name: "GenderSelect",
7
7
  props: {
@@ -266,8 +266,8 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
266
266
  };
267
267
  }
268
268
  });
269
- const _hoisted_1 = { class: "row" };
270
- const _hoisted_2 = {
269
+ const _hoisted_1$1 = { class: "row" };
270
+ const _hoisted_2$1 = {
271
271
  key: 0,
272
272
  style: { "margin-top": "1em", "width": "1ch" }
273
273
  };
@@ -440,7 +440,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
440
440
  "stack-label": ""
441
441
  }, createSlots({
442
442
  control: withCtx(() => [
443
- createElementVNode("div", _hoisted_1, [
443
+ createElementVNode("div", _hoisted_1$1, [
444
444
  (openBlock(true), createElementBlock(Fragment, null, renderList(unref(format).split("-"), (part, index) => {
445
445
  return openBlock(), createBlock(resolveDynamicComponent(unref(QInput)), mergeProps({
446
446
  key: part,
@@ -456,7 +456,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
456
456
  dense: ""
457
457
  }), {
458
458
  after: withCtx(() => [
459
- index < 2 ? (openBlock(), createElementBlock("a", _hoisted_2, "-")) : createCommentVNode("", true)
459
+ index < 2 ? (openBlock(), createElementBlock("a", _hoisted_2$1, "-")) : createCommentVNode("", true)
460
460
  ]),
461
461
  _: 2
462
462
  }, 1040);
@@ -900,6 +900,11 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
900
900
  };
901
901
  }
902
902
  });
903
+ const _hoisted_1 = { class: "row" };
904
+ const _hoisted_2 = {
905
+ key: 0,
906
+ class: "row"
907
+ };
903
908
  const _sfc_main = /* @__PURE__ */ defineComponent({
904
909
  __name: "CronScheduleInput",
905
910
  props: {
@@ -939,7 +944,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
939
944
  }))
940
945
  ]);
941
946
  const dayOfWeekOptions = ref(
942
- [...Array(31).keys()].map((day) => ({
947
+ [...Array(7).keys()].map((day) => ({
943
948
  label: $q.lang.date.days[day],
944
949
  value: String(day)
945
950
  }))
@@ -965,6 +970,22 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
965
970
  dayOfWeek.value = newDayOfWeek.split(",").filter((val) => val !== "*");
966
971
  }
967
972
  }
973
+ const smallStyle = {
974
+ "margin-top": "-1.75em",
975
+ "margin-bottom": "-0.5em",
976
+ background: "transparent",
977
+ border: 0
978
+ };
979
+ const largeStyle = {
980
+ "margin-bottom": "-0.5em",
981
+ background: "transparent",
982
+ border: 0
983
+ };
984
+ const dayOfWeekStyle = {
985
+ "margin-bottom": "-0.5em",
986
+ background: "transparent",
987
+ border: 0
988
+ };
968
989
  watch(modelValue, (newVal) => {
969
990
  if (newVal) setInternalCron(newVal);
970
991
  else if (newVal === null) {
@@ -983,109 +1004,125 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
983
1004
  borderless: ""
984
1005
  }, {
985
1006
  control: withCtx(() => [
986
- _ctx.showHour ? (openBlock(), createBlock(_component_q_select, {
987
- key: 0,
988
- modelValue: hour.value,
989
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => hour.value = $event),
990
- options: hourOptions.value,
991
- hint: unref(lang).cron.hour,
992
- "bottom-slots": "",
993
- style: {
994
- width: "10ch",
995
- "margin-top": "-2em",
996
- "margin-bottom": "-0.5em"
997
- },
998
- "map-options": "",
999
- "emit-value": "",
1000
- multiple: ""
1001
- }, {
1002
- selected: withCtx(() => [
1003
- createTextVNode(toDisplayString(hour.value.length ? hour.value.join(",") : unref(lang).cron.every.hour), 1)
1004
- ]),
1005
- _: 1
1006
- }, 8, ["modelValue", "options", "hint"])) : createCommentVNode("", true),
1007
- _ctx.showMinute ? (openBlock(), createBlock(_component_q_select, {
1008
- key: 1,
1009
- modelValue: minute.value,
1010
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => minute.value = $event),
1011
- options: minuteOptions.value,
1012
- hint: unref(lang).cron.minute,
1013
- "bottom-slots": "",
1014
- style: {
1015
- width: "10ch",
1016
- "margin-top": "-2em",
1017
- "margin-bottom": "-0.5em"
1018
- },
1019
- "map-options": "",
1020
- "emit-value": "",
1021
- multiple: ""
1022
- }, {
1023
- selected: withCtx(() => [
1024
- createTextVNode(toDisplayString(minute.value.length ? minute.value.join(",") : unref(lang).cron.every.minute), 1)
1025
- ]),
1026
- _: 1
1027
- }, 8, ["modelValue", "options", "hint"])) : createCommentVNode("", true),
1028
- createVNode(_component_q_select, {
1029
- modelValue: dayOfMonth.value,
1030
- "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => dayOfMonth.value = $event),
1031
- options: dayOfMonthOptions.value,
1032
- hint: unref(lang).cron.dayOfMonth,
1033
- "bottom-slots": "",
1034
- style: {
1035
- width: "10ch",
1036
- "margin-top": "-2em",
1037
- "margin-bottom": "-0.5em"
1038
- },
1039
- "map-options": "",
1040
- "emit-value": "",
1041
- multiple: ""
1042
- }, {
1043
- selected: withCtx(() => [
1044
- createTextVNode(toDisplayString(dayOfMonth.value.length ? dayOfMonth.value.join(",") : unref(lang).cron.every.dayOfMonth), 1)
1045
- ]),
1046
- _: 1
1047
- }, 8, ["modelValue", "options", "hint"]),
1048
- createVNode(_component_q_select, {
1049
- modelValue: month.value,
1050
- "onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => month.value = $event),
1051
- options: monthOptions.value,
1052
- hint: unref(lang).cron.month,
1053
- placeholder: unref(lang).cron.month,
1054
- "bottom-slots": "",
1055
- style: {
1056
- width: "16ch",
1057
- "margin-top": "-2em",
1058
- "margin-bottom": "-0.5em"
1059
- },
1060
- "map-options": "",
1061
- "emit-value": "",
1062
- multiple: ""
1063
- }, {
1064
- selected: withCtx(() => [
1065
- createTextVNode(toDisplayString(month.value.length ? month.value.map((val) => unref($q).lang.date.months[Number(val) - 1]).join(",") : unref(lang).cron.every.month), 1)
1066
- ]),
1067
- _: 1
1068
- }, 8, ["modelValue", "options", "hint", "placeholder"]),
1069
- _ctx.showDayOfWeek ? (openBlock(), createBlock(_component_q_select, {
1070
- key: 2,
1071
- modelValue: dayOfWeek.value,
1072
- "onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => dayOfWeek.value = $event),
1073
- options: dayOfWeekOptions.value,
1074
- placeholder: unref(lang).cron.dayOfWeek,
1075
- style: {
1076
- width: "16ch",
1077
- "margin-top": "-2em",
1078
- "margin-bottom": "-0.5em"
1079
- },
1080
- "map-options": "",
1081
- "emit-value": "",
1082
- multiple: ""
1083
- }, {
1084
- selected: withCtx(() => [
1085
- createTextVNode(toDisplayString(dayOfWeek.value.length ? dayOfWeek.value.map((val) => unref($q).lang.date.days[Number(val)]).join(",") : unref(lang).cron.every.dayOfWeek), 1)
1086
- ]),
1087
- _: 1
1088
- }, 8, ["modelValue", "options", "placeholder"])) : createCommentVNode("", true)
1007
+ createElementVNode("div", _hoisted_1, [
1008
+ _ctx.showHour ? (openBlock(), createBlock(_component_q_select, {
1009
+ key: 0,
1010
+ modelValue: hour.value,
1011
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => hour.value = $event),
1012
+ class: "col-auto",
1013
+ options: hourOptions.value,
1014
+ hint: unref(lang).cron.hour,
1015
+ "bottom-slots": "",
1016
+ borderless: "",
1017
+ filled: false,
1018
+ outlined: false,
1019
+ standout: false,
1020
+ rounded: false,
1021
+ style: smallStyle,
1022
+ "map-options": "",
1023
+ "emit-value": "",
1024
+ multiple: ""
1025
+ }, {
1026
+ selected: withCtx(() => [
1027
+ createTextVNode(toDisplayString(hour.value.length ? hour.value.join(",") : unref(lang).cron.every.hour), 1)
1028
+ ]),
1029
+ _: 1
1030
+ }, 8, ["modelValue", "options", "hint"])) : createCommentVNode("", true),
1031
+ _ctx.showMinute ? (openBlock(), createBlock(_component_q_select, {
1032
+ key: 1,
1033
+ modelValue: minute.value,
1034
+ "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => minute.value = $event),
1035
+ class: "col-auto",
1036
+ options: minuteOptions.value,
1037
+ hint: unref(lang).cron.minute,
1038
+ "bottom-slots": "",
1039
+ borderless: "",
1040
+ filled: false,
1041
+ outlined: false,
1042
+ standout: false,
1043
+ rounded: false,
1044
+ style: smallStyle,
1045
+ "map-options": "",
1046
+ "emit-value": "",
1047
+ multiple: ""
1048
+ }, {
1049
+ selected: withCtx(() => [
1050
+ createTextVNode(toDisplayString(minute.value.length ? minute.value.join(",") : unref(lang).cron.every.minute), 1)
1051
+ ]),
1052
+ _: 1
1053
+ }, 8, ["modelValue", "options", "hint"])) : createCommentVNode("", true),
1054
+ createVNode(_component_q_select, {
1055
+ modelValue: dayOfMonth.value,
1056
+ "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => dayOfMonth.value = $event),
1057
+ class: "col-auto",
1058
+ options: dayOfMonthOptions.value,
1059
+ hint: unref(lang).cron.dayOfMonth,
1060
+ "bottom-slots": "",
1061
+ borderless: "",
1062
+ filled: false,
1063
+ outlined: false,
1064
+ standout: false,
1065
+ rounded: false,
1066
+ style: smallStyle,
1067
+ "map-options": "",
1068
+ "emit-value": "",
1069
+ multiple: ""
1070
+ }, {
1071
+ selected: withCtx(() => [
1072
+ createTextVNode(toDisplayString(dayOfMonth.value.length ? dayOfMonth.value.join(",") : unref(lang).cron.every.dayOfMonth), 1)
1073
+ ]),
1074
+ _: 1
1075
+ }, 8, ["modelValue", "options", "hint"]),
1076
+ createVNode(_component_q_select, {
1077
+ modelValue: month.value,
1078
+ "onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => month.value = $event),
1079
+ class: "col-auto",
1080
+ options: monthOptions.value,
1081
+ hint: unref(lang).cron.month,
1082
+ placeholder: unref(lang).cron.month,
1083
+ "bottom-slots": "",
1084
+ borderless: "",
1085
+ filled: false,
1086
+ outlined: false,
1087
+ standout: false,
1088
+ rounded: false,
1089
+ style: largeStyle,
1090
+ "map-options": "",
1091
+ "emit-value": "",
1092
+ multiple: ""
1093
+ }, {
1094
+ selected: withCtx(() => [
1095
+ createTextVNode(toDisplayString(month.value.length ? month.value.map((val) => unref($q).lang.date.months[Number(val) - 1]).join(",") : unref(lang).cron.every.month), 1)
1096
+ ]),
1097
+ _: 1
1098
+ }, 8, ["modelValue", "options", "hint", "placeholder"])
1099
+ ]),
1100
+ _ctx.showDayOfWeek ? (openBlock(), createElementBlock("div", _hoisted_2, [
1101
+ _ctx.showDayOfWeek ? (openBlock(), createBlock(_component_q_select, {
1102
+ key: 0,
1103
+ modelValue: dayOfWeek.value,
1104
+ "onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => dayOfWeek.value = $event),
1105
+ class: "col-auto",
1106
+ options: dayOfWeekOptions.value,
1107
+ placeholder: unref(lang).cron.dayOfWeek,
1108
+ hint: unref(lang).cron.dayOfWeek,
1109
+ style: dayOfWeekStyle,
1110
+ "bottom-slots": "",
1111
+ borderless: "",
1112
+ filled: false,
1113
+ outlined: false,
1114
+ standout: false,
1115
+ rounded: false,
1116
+ "map-options": "",
1117
+ "emit-value": "",
1118
+ multiple: ""
1119
+ }, {
1120
+ selected: withCtx(() => [
1121
+ createTextVNode(toDisplayString(dayOfWeek.value.length ? dayOfWeek.value.map((val) => unref($q).lang.date.days[Number(val)]).join(",") : unref(lang).cron.every.dayOfWeek), 1)
1122
+ ]),
1123
+ _: 1
1124
+ }, 8, ["modelValue", "options", "placeholder", "hint"])) : createCommentVNode("", true)
1125
+ ])) : createCommentVNode("", true)
1089
1126
  ]),
1090
1127
  _: 1
1091
1128
  }, 8, ["model-value", "rules", "label"]);
package/dist/general.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { u as useLang, l as loadLang, _ as _sfc_main$5 } from "./QSubmitButton.vue_vue_type_script_setup_true_lang-UtpXkOh7.js";
2
2
  import { useQuasar, QCard, QCardSection, QCardActions, QDialog, QLayout, QHeader, QToolbar, QBtn, QToolbarTitle, QPageContainer, QPage, QPageSticky, QSpace, QList } from "quasar";
3
3
  import { defineComponent, watch, ref, createBlock, openBlock, unref, withCtx, renderSlot, createVNode, createElementVNode, normalizeProps, guardReactiveProps, createCommentVNode, toRefs, normalizeClass, createElementBlock } from "vue";
4
- import { _ as _sfc_main$6 } from "./LocaleSelect.vue_vue_type_script_setup_true_lang-Du4fNbTV.js";
4
+ import { _ as _sfc_main$6 } from "./LocaleSelect.vue_vue_type_script_setup_true_lang-DmbnGyqQ.js";
5
5
  const _hoisted_1$1 = { class: "text-h6" };
6
6
  const _hoisted_2$1 = { class: "text-subtitle2" };
7
7
  const __default__$2 = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@simsustech/quasar-components",
3
- "version": "0.11.13",
3
+ "version": "0.11.15",
4
4
  "author": "Stefan van Herwijnen",
5
5
  "description": "High level components for Quasar Framework",
6
6
  "license": "MIT",
@@ -7,113 +7,131 @@
7
7
  borderless
8
8
  >
9
9
  <template #control>
10
- <q-select
11
- v-if="showHour"
12
- v-model="hour"
13
- :options="hourOptions"
14
- :hint="lang.cron.hour"
15
- bottom-slots
16
- :style="{
17
- width: '10ch',
18
- 'margin-top': '-2em',
19
- 'margin-bottom': '-0.5em'
20
- }"
21
- map-options
22
- emit-value
23
- multiple
24
- >
25
- <template #selected>
26
- {{ hour.length ? hour.join(',') : lang.cron.every.hour }}
27
- </template>
28
- </q-select>
29
- <q-select
30
- v-if="showMinute"
31
- v-model="minute"
32
- :options="minuteOptions"
33
- :hint="lang.cron.minute"
34
- bottom-slots
35
- :style="{
36
- width: '10ch',
37
- 'margin-top': '-2em',
38
- 'margin-bottom': '-0.5em'
39
- }"
40
- map-options
41
- emit-value
42
- multiple
43
- >
44
- <template #selected>
45
- {{ minute.length ? minute.join(',') : lang.cron.every.minute }}
46
- </template>
47
- </q-select>
48
- <q-select
49
- v-model="dayOfMonth"
50
- :options="dayOfMonthOptions"
51
- :hint="lang.cron.dayOfMonth"
52
- bottom-slots
53
- :style="{
54
- width: '10ch',
55
- 'margin-top': '-2em',
56
- 'margin-bottom': '-0.5em'
57
- }"
58
- map-options
59
- emit-value
60
- multiple
61
- >
62
- <template #selected>
63
- {{
64
- dayOfMonth.length
65
- ? dayOfMonth.join(',')
66
- : lang.cron.every.dayOfMonth
67
- }}
68
- </template>
69
- </q-select>
70
- <q-select
71
- v-model="month"
72
- :options="monthOptions"
73
- :hint="lang.cron.month"
74
- :placeholder="lang.cron.month"
75
- bottom-slots
76
- :style="{
77
- width: '16ch',
78
- 'margin-top': '-2em',
79
- 'margin-bottom': '-0.5em'
80
- }"
81
- map-options
82
- emit-value
83
- multiple
84
- >
85
- <template #selected>
86
- {{
87
- month.length
88
- ? month
89
- .map((val) => $q.lang.date.months[Number(val) - 1])
90
- .join(',')
91
- : lang.cron.every.month
92
- }}
93
- </template>
94
- </q-select>
95
- <q-select
96
- v-if="showDayOfWeek"
97
- v-model="dayOfWeek"
98
- :options="dayOfWeekOptions"
99
- :placeholder="lang.cron.dayOfWeek"
100
- :style="{
101
- width: '16ch',
102
- 'margin-top': '-2em',
103
- 'margin-bottom': '-0.5em'
104
- }"
105
- map-options
106
- emit-value
107
- multiple
108
- >
109
- <template #selected>
110
- {{
111
- dayOfWeek.length
112
- ? dayOfWeek.map((val) => $q.lang.date.days[Number(val)]).join(',')
113
- : lang.cron.every.dayOfWeek
114
- }}
115
- </template>
116
- </q-select>
10
+ <div class="row">
11
+ <q-select
12
+ v-if="showHour"
13
+ v-model="hour"
14
+ class="col-auto"
15
+ :options="hourOptions"
16
+ :hint="lang.cron.hour"
17
+ bottom-slots
18
+ borderless
19
+ :filled="false"
20
+ :outlined="false"
21
+ :standout="false"
22
+ :rounded="false"
23
+ :style="smallStyle"
24
+ map-options
25
+ emit-value
26
+ multiple
27
+ >
28
+ <template #selected>
29
+ {{ hour.length ? hour.join(',') : lang.cron.every.hour }}
30
+ </template>
31
+ </q-select>
32
+ <q-select
33
+ v-if="showMinute"
34
+ v-model="minute"
35
+ class="col-auto"
36
+ :options="minuteOptions"
37
+ :hint="lang.cron.minute"
38
+ bottom-slots
39
+ borderless
40
+ :filled="false"
41
+ :outlined="false"
42
+ :standout="false"
43
+ :rounded="false"
44
+ :style="smallStyle"
45
+ map-options
46
+ emit-value
47
+ multiple
48
+ >
49
+ <template #selected>
50
+ {{ minute.length ? minute.join(',') : lang.cron.every.minute }}
51
+ </template>
52
+ </q-select>
53
+ <q-select
54
+ v-model="dayOfMonth"
55
+ class="col-auto"
56
+ :options="dayOfMonthOptions"
57
+ :hint="lang.cron.dayOfMonth"
58
+ bottom-slots
59
+ borderless
60
+ :filled="false"
61
+ :outlined="false"
62
+ :standout="false"
63
+ :rounded="false"
64
+ :style="smallStyle"
65
+ map-options
66
+ emit-value
67
+ multiple
68
+ >
69
+ <template #selected>
70
+ {{
71
+ dayOfMonth.length
72
+ ? dayOfMonth.join(',')
73
+ : lang.cron.every.dayOfMonth
74
+ }}
75
+ </template>
76
+ </q-select>
77
+ <q-select
78
+ v-model="month"
79
+ class="col-auto"
80
+ :options="monthOptions"
81
+ :hint="lang.cron.month"
82
+ :placeholder="lang.cron.month"
83
+ bottom-slots
84
+ borderless
85
+ :filled="false"
86
+ :outlined="false"
87
+ :standout="false"
88
+ :rounded="false"
89
+ :style="largeStyle"
90
+ map-options
91
+ emit-value
92
+ multiple
93
+ >
94
+ <template #selected>
95
+ {{
96
+ month.length
97
+ ? month
98
+ .map((val) => $q.lang.date.months[Number(val) - 1])
99
+ .join(',')
100
+ : lang.cron.every.month
101
+ }}
102
+ </template>
103
+ </q-select>
104
+ </div>
105
+ <div v-if="showDayOfWeek" class="row">
106
+ <q-select
107
+ v-if="showDayOfWeek"
108
+ v-model="dayOfWeek"
109
+ class="col-auto"
110
+ :options="dayOfWeekOptions"
111
+ :placeholder="lang.cron.dayOfWeek"
112
+ :hint="lang.cron.dayOfWeek"
113
+ :style="dayOfWeekStyle"
114
+ bottom-slots
115
+ borderless
116
+ :filled="false"
117
+ :outlined="false"
118
+ :standout="false"
119
+ :rounded="false"
120
+ map-options
121
+ emit-value
122
+ multiple
123
+ >
124
+ <template #selected>
125
+ {{
126
+ dayOfWeek.length
127
+ ? dayOfWeek
128
+ .map((val) => $q.lang.date.days[Number(val)])
129
+ .join(',')
130
+ : lang.cron.every.dayOfWeek
131
+ }}
132
+ </template>
133
+ </q-select>
134
+ </div>
117
135
  </template>
118
136
  </q-field>
119
137
  </template>
@@ -163,7 +181,7 @@ const monthOptions = ref([
163
181
  }))
164
182
  ])
165
183
  const dayOfWeekOptions = ref(
166
- [...Array(31).keys()].map((day) => ({
184
+ [...Array(7).keys()].map((day) => ({
167
185
  label: $q.lang.date.days[day],
168
186
  value: String(day)
169
187
  }))
@@ -195,6 +213,25 @@ function setInternalCron(cronString: string) {
195
213
  }
196
214
  }
197
215
 
216
+ const smallStyle = {
217
+ 'margin-top': '-1.75em',
218
+ 'margin-bottom': '-0.5em',
219
+ background: 'transparent',
220
+ border: 0
221
+ }
222
+
223
+ const largeStyle = {
224
+ 'margin-bottom': '-0.5em',
225
+ background: 'transparent',
226
+ border: 0
227
+ }
228
+
229
+ const dayOfWeekStyle = {
230
+ 'margin-bottom': '-0.5em',
231
+ background: 'transparent',
232
+ border: 0
233
+ }
234
+
198
235
  watch(modelValue, (newVal) => {
199
236
  if (newVal) setInternalCron(newVal)
200
237
  else if (newVal === null) {
@@ -4,20 +4,13 @@
4
4
  :options="languageOptions"
5
5
  :model-value="modelValue"
6
6
  :filled="false"
7
- borderless
8
7
  emit-value
9
8
  map-options
10
9
  >
11
10
  <template #selected-item="scope">
12
11
  <div v-if="scope.opt">
13
- <q-item>
14
- <q-item-section avatar>
15
- <q-icon :name="scope.opt.icon" />
16
- </q-item-section>
17
- <q-item-section label>
18
- {{ scope.opt.label }}
19
- </q-item-section>
20
- </q-item>
12
+ <q-icon :name="scope.opt.icon" />
13
+ {{ scope.opt.label }}
21
14
  </div>
22
15
  </template>
23
16
  <template #option="scope">