@bagelink/vue 0.0.186 → 0.0.190

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.
Files changed (119) hide show
  1. package/dist/components/Btn.vue.d.ts +1 -1
  2. package/dist/components/Btn.vue.d.ts.map +1 -1
  3. package/dist/components/Comments.vue.d.ts +1 -1
  4. package/dist/components/Comments.vue.d.ts.map +1 -1
  5. package/dist/components/ContactSubmissions.vue.d.ts +1 -1
  6. package/dist/components/DataPreview.vue.d.ts +1 -1
  7. package/dist/components/DataPreview.vue.d.ts.map +1 -1
  8. package/dist/components/DropDown.vue.d.ts +1 -1
  9. package/dist/components/FormSchema.vue.d.ts +1 -1
  10. package/dist/components/FormSchema.vue.d.ts.map +1 -1
  11. package/dist/components/LangText.vue.d.ts +1 -1
  12. package/dist/components/LangText.vue.d.ts.map +1 -1
  13. package/dist/components/ListItem.vue.d.ts +1 -1
  14. package/dist/components/ListItem.vue.d.ts.map +1 -1
  15. package/dist/components/ListView.vue.d.ts +3 -3
  16. package/dist/components/ListView.vue.d.ts.map +1 -1
  17. package/dist/components/MaterialIcon.vue.d.ts +1 -1
  18. package/dist/components/MaterialIcon.vue.d.ts.map +1 -1
  19. package/dist/components/Modal.vue.d.ts +1 -1
  20. package/dist/components/Modal.vue.d.ts.map +1 -1
  21. package/dist/components/ModalForm.vue.d.ts +1 -1
  22. package/dist/components/ModalForm.vue.d.ts.map +1 -1
  23. package/dist/components/NavBar.vue.d.ts +1 -1
  24. package/dist/components/NavBar.vue.d.ts.map +1 -1
  25. package/dist/components/PageTitle.vue.d.ts +1 -1
  26. package/dist/components/PageTitle.vue.d.ts.map +1 -1
  27. package/dist/components/PersonPreview.vue.d.ts +1 -1
  28. package/dist/components/PersonPreview.vue.d.ts.map +1 -1
  29. package/dist/components/PersonPreviewFormkit.vue.d.ts +1 -1
  30. package/dist/components/PersonPreviewFormkit.vue.d.ts.map +1 -1
  31. package/dist/components/RTXEditor.vue.d.ts +1 -1
  32. package/dist/components/RTXEditor.vue.d.ts.map +1 -1
  33. package/dist/components/RouterWrapper.vue.d.ts +1 -1
  34. package/dist/components/TabbedLayout.vue.d.ts +1 -1
  35. package/dist/components/TabbedLayout.vue.d.ts.map +1 -1
  36. package/dist/components/TableSchema.vue.d.ts +1 -1
  37. package/dist/components/TableSchema.vue.d.ts.map +1 -1
  38. package/dist/components/TopBar.vue.d.ts +1 -1
  39. package/dist/components/TopBar.vue.d.ts.map +1 -1
  40. package/dist/components/charts/BarChart.vue.d.ts +1 -1
  41. package/dist/components/charts/BarChart.vue.d.ts.map +1 -1
  42. package/dist/components/dashboard/Lineart.vue.d.ts +2 -2
  43. package/dist/components/dashboard/Lineart.vue.d.ts.map +1 -1
  44. package/dist/components/form/ItemRef.vue.d.ts +1 -1
  45. package/dist/components/form/ItemRef.vue.d.ts.map +1 -1
  46. package/dist/components/form/MaterialIcon.vue.d.ts +1 -1
  47. package/dist/components/form/MaterialIcon.vue.d.ts.map +1 -1
  48. package/dist/components/form/PlainInputField.vue.d.ts +1 -1
  49. package/dist/components/form/PlainInputField.vue.d.ts.map +1 -1
  50. package/dist/components/form/inputs/CheckInput.vue.d.ts +1 -1
  51. package/dist/components/form/inputs/CheckInput.vue.d.ts.map +1 -1
  52. package/dist/components/form/inputs/Checkbox.vue.d.ts +1 -1
  53. package/dist/components/form/inputs/ColorPicker.vue.d.ts +1 -1
  54. package/dist/components/form/inputs/ColorPicker.vue.d.ts.map +1 -1
  55. package/dist/components/form/inputs/CurrencyInput.vue.d.ts +1 -1
  56. package/dist/components/form/inputs/CurrencyInput.vue.d.ts.map +1 -1
  57. package/dist/components/form/inputs/DateInput.vue.d.ts +1 -1
  58. package/dist/components/form/inputs/DateInput.vue.d.ts.map +1 -1
  59. package/dist/components/form/inputs/DatePicker.vue.d.ts +20 -0
  60. package/dist/components/form/inputs/DatePicker.vue.d.ts.map +1 -0
  61. package/dist/components/form/inputs/DatetimeInput.vue.d.ts +1 -1
  62. package/dist/components/form/inputs/DatetimeInput.vue.d.ts.map +1 -1
  63. package/dist/components/form/inputs/DurationInput.vue.d.ts +1 -1
  64. package/dist/components/form/inputs/DurationInput.vue.d.ts.map +1 -1
  65. package/dist/components/form/inputs/DynamicLinkField.vue.d.ts +1 -1
  66. package/dist/components/form/inputs/DynamicLinkField.vue.d.ts.map +1 -1
  67. package/dist/components/form/inputs/EmailInput.vue.d.ts +1 -1
  68. package/dist/components/form/inputs/EmailInput.vue.d.ts.map +1 -1
  69. package/dist/components/form/inputs/FloatInput.vue.d.ts +1 -1
  70. package/dist/components/form/inputs/FloatInput.vue.d.ts.map +1 -1
  71. package/dist/components/form/inputs/IntInput.vue.d.ts +1 -1
  72. package/dist/components/form/inputs/IntInput.vue.d.ts.map +1 -1
  73. package/dist/components/form/inputs/JSONInput.vue.d.ts +1 -1
  74. package/dist/components/form/inputs/JSONInput.vue.d.ts.map +1 -1
  75. package/dist/components/form/inputs/LinkField.vue.d.ts +1 -1
  76. package/dist/components/form/inputs/LinkField.vue.d.ts.map +1 -1
  77. package/dist/components/form/inputs/Password.vue.d.ts +1 -1
  78. package/dist/components/form/inputs/Password.vue.d.ts.map +1 -1
  79. package/dist/components/form/inputs/PasswordInput.vue.d.ts +1 -1
  80. package/dist/components/form/inputs/PasswordInput.vue.d.ts.map +1 -1
  81. package/dist/components/form/inputs/PlainText.vue.d.ts +1 -1
  82. package/dist/components/form/inputs/PlainText.vue.d.ts.map +1 -1
  83. package/dist/components/form/inputs/ReadOnlyInput.vue.d.ts +1 -1
  84. package/dist/components/form/inputs/ReadOnlyInput.vue.d.ts.map +1 -1
  85. package/dist/components/form/inputs/RichTextEditor.vue.d.ts +1 -1
  86. package/dist/components/form/inputs/RichTextEditor.vue.d.ts.map +1 -1
  87. package/dist/components/form/inputs/SelectField.vue.d.ts +1 -1
  88. package/dist/components/form/inputs/SelectField.vue.d.ts.map +1 -1
  89. package/dist/components/form/inputs/TableField.vue.d.ts +1 -1
  90. package/dist/components/form/inputs/TableField.vue.d.ts.map +1 -1
  91. package/dist/components/form/inputs/TextArea.vue.d.ts +1 -1
  92. package/dist/components/form/inputs/TextArea.vue.d.ts.map +1 -1
  93. package/dist/components/form/inputs/TextInput.vue.d.ts +1 -1
  94. package/dist/components/form/inputs/TextInput.vue.d.ts.map +1 -1
  95. package/dist/components/form/inputs/index.d.ts +1 -0
  96. package/dist/components/form/inputs/index.d.ts.map +1 -1
  97. package/dist/components/formkit/AddressArray.vue.d.ts +1 -1
  98. package/dist/components/formkit/AddressArray.vue.d.ts.map +1 -1
  99. package/dist/components/formkit/BankDetailsArray.vue.d.ts +1 -1
  100. package/dist/components/formkit/BankDetailsArray.vue.d.ts.map +1 -1
  101. package/dist/components/formkit/ContactArrayFormKit.vue.d.ts +1 -1
  102. package/dist/components/formkit/ContactArrayFormKit.vue.d.ts.map +1 -1
  103. package/dist/components/formkit/FileUploader.vue.d.ts +1 -1
  104. package/dist/components/formkit/FileUploader.vue.d.ts.map +1 -1
  105. package/dist/components/formkit/MiscFields.vue.d.ts +1 -1
  106. package/dist/components/formkit/MiscFields.vue.d.ts.map +1 -1
  107. package/dist/components/formkit/Toggle.vue.d.ts +1 -1
  108. package/dist/components/whatsapp/form/MsgTemplate.vue.d.ts +1 -1
  109. package/dist/components/whatsapp/form/MsgTemplate.vue.d.ts.map +1 -1
  110. package/dist/components/whatsapp/form/TextVariableExamples.vue.d.ts +1 -1
  111. package/dist/index.cjs +563 -489
  112. package/dist/index.mjs +564 -490
  113. package/dist/style.css +204 -102
  114. package/package.json +20 -17
  115. package/src/components/TableSchema.vue +79 -70
  116. package/src/components/dashboard/Lineart.vue +136 -115
  117. package/src/components/form/inputs/DatePicker.vue +153 -0
  118. package/src/components/form/inputs/index.ts +1 -0
  119. package/src/components/formkit/FileUploader.vue +8 -6
@@ -1,100 +1,121 @@
1
1
  <template>
2
- <div ref="chartContainer" class="chart-line">
3
- <Chart
4
- v-if="chartSize"
5
- :size="chartSize"
6
- :data="data"
7
- :margin="chartMargin"
8
- :axis="axisConfig"
9
- >
10
- <template #layers>
11
- <Grid :center="true" strokeDasharray="2,2" :hideY="true" />
12
- <Area
13
- aria-label="Profit/Loss"
14
- :dataKeys="['date', 'total_value']"
15
- type="monotone"
16
- :areaStyle="{ fill: 'url(#grad)' }"
17
- />
18
- <Line
19
- :dataKeys="['date', 'total_value']"
20
- type="monotone"
21
- :dotStyle="dotStyling"
22
- :lineStyle="{ stroke: BRAND_COLOR, r: 2 }"
23
- />
24
- <Marker
25
- v-if="displayMarker"
26
- :value="meanValue"
27
- label="ממוצע"
28
- :color="BRAND_COLOR"
29
- :strokeWidth="2"
30
- strokeDasharray="6 6"
31
- />
32
- <defs>
33
- <linearGradient id="grad" gradientTransform="rotate(90)">
34
- <stop offset="0%" :stop-color="BRAND_COLOR" stop-opacity="1" />
35
- <stop offset="100%" stop-color="white" stop-opacity="0.4" />
36
- </linearGradient>
37
- </defs>
38
- </template>
39
- <template #widgets>
40
- <Tooltip color="white" :config="tooltipConfiguration" />
41
- </template>
42
- </Chart>
43
- </div>
2
+ <div
3
+ ref="chartContainer"
4
+ class="chart-line"
5
+ >
6
+ <Chart
7
+ v-if="chartSize"
8
+ :size="chartSize"
9
+ :data="data"
10
+ :margin="chartMargin"
11
+ :axis="axisConfig"
12
+ >
13
+ <template #layers>
14
+ <Grid
15
+ :center="true"
16
+ strokeDasharray="2,2"
17
+ :hideY="true"
18
+ />
19
+ <Area
20
+ aria-label="Profit/Loss"
21
+ :dataKeys="['date', 'total_value']"
22
+ type="monotone"
23
+ :areaStyle="{ fill: 'url(#grad)' }"
24
+ />
25
+ <Line
26
+ :dataKeys="['date', 'total_value']"
27
+ type="monotone"
28
+ :dotStyle="dotStyling"
29
+ :lineStyle="{ stroke: BRAND_COLOR, r: 2 }"
30
+ />
31
+ <Marker
32
+ v-if="displayMarker"
33
+ :value="meanValue"
34
+ label="ממוצע"
35
+ :color="BRAND_COLOR"
36
+ :strokeWidth="2"
37
+ strokeDasharray="6 6"
38
+ />
39
+ <defs>
40
+ <linearGradient
41
+ id="grad"
42
+ gradientTransform="rotate(90)"
43
+ >
44
+ <stop
45
+ offset="0%"
46
+ :stop-color="BRAND_COLOR"
47
+ stop-opacity="1"
48
+ />
49
+ <stop
50
+ offset="100%"
51
+ stop-color="white"
52
+ stop-opacity="0.4"
53
+ />
54
+ </linearGradient>
55
+ </defs>
56
+ </template>
57
+ <template #widgets>
58
+ <Tooltip
59
+ color="white"
60
+ :config="tooltipConfiguration"
61
+ />
62
+ </template>
63
+ </Chart>
64
+ </div>
44
65
  </template>
45
66
 
46
67
  <script lang="ts" setup>
47
- import { onMounted, onUnmounted } from "vue";
48
- import { Chart, Grid, Line, Area, Tooltip, Marker } from "vue3-charts";
49
- import type { ChartAxis, Data } from "vue3-charts/dist/types";
68
+ import { onMounted, onUnmounted } from 'vue';
69
+ import {
70
+ Chart, Grid, Line, Area, Tooltip, Marker,
71
+ } from 'vue3-charts';
72
+ import type { ChartAxis, Data } from 'vue3-charts/dist/types';
50
73
 
51
74
  const props = defineProps<{ data: Data[]; locale: string }>();
52
75
 
53
- const data = $computed(() =>
54
- props.locale === "he" ? [...props.data].reverse() : props.data
55
- );
76
+ const data = $computed(() => (props.locale === 'he' ? [...props.data].reverse() : props.data));
56
77
 
57
78
  interface Size {
58
- width: number;
59
- height: number;
79
+ width: number;
80
+ height: number;
60
81
  }
61
82
 
62
83
  // Computed properties
63
84
  const meanValue = $computed(() => {
64
- const sum = props.data.reduce((acc, curr) => acc + +curr.total_value, 0);
65
- return sum / props.data.length;
85
+ const sum = props.data.reduce((acc, curr) => acc + +curr.total_value, 0);
86
+ return sum / props.data.length;
66
87
  });
67
88
 
68
89
  const axisConfig = $computed<ChartAxis>(() => ({
69
- primary: {
70
- type: "band",
71
- rotate: true,
72
- ticks: 5,
73
- domain: ["dataMin", "dataMax"],
74
- tickValues:
75
- props.data?.length > 100 ? [""] : props.data.map((d: any) => d.date),
76
- },
77
- secondary: {
78
- domain: ["dataMin", "dataMax * 1.05"],
79
- type: "linear",
80
- ticks: 8,
81
- },
90
+ primary: {
91
+ type: 'band',
92
+ rotate: true,
93
+ ticks: 5,
94
+ domain: ['dataMin', 'dataMax'],
95
+ tickValues:
96
+ props.data?.length > 100 ? [''] : props.data.map((d: any) => d.date),
97
+ },
98
+ secondary: {
99
+ domain: ['dataMin', 'dataMax * 1.05'],
100
+ type: 'linear',
101
+ ticks: 8,
102
+ },
82
103
  }));
83
104
 
84
105
  // Constants
85
- const BRAND_COLOR = "var(--bgl-primary)";
106
+ const BRAND_COLOR = 'var(--bgl-primary)';
86
107
 
87
108
  const tooltipConfiguration = {
88
- date: { label: "תאריך" },
89
- total_value: {
90
- color: BRAND_COLOR,
91
- label: "סכום",
92
- format: (v: number) => `₪${v.toLocaleString()}`,
93
- },
94
- total_count: {
95
- label: "מספר התרומות",
96
- format: (v: number) => `${v.toLocaleString()}`,
97
- },
109
+ date: { label: 'תאריך' },
110
+ total_value: {
111
+ color: BRAND_COLOR,
112
+ label: 'סכום',
113
+ format: (v: number) => `₪${v?.toLocaleString?.() || ''}`,
114
+ },
115
+ total_count: {
116
+ label: 'מספר התרומות',
117
+ format: (v: number) => `${v?.toLocaleString?.() || ''}`,
118
+ },
98
119
  };
99
120
 
100
121
  // Refs
@@ -102,83 +123,83 @@ let chartSize = $ref<Size | null>(null);
102
123
  const chartContainer = $ref<HTMLElement>();
103
124
  const displayMarker = $ref(true);
104
125
  const chartMargin = $ref({
105
- left: 0,
106
- top: 0,
107
- right: 0,
108
- bottom: 0,
126
+ left: 0,
127
+ top: 0,
128
+ right: 0,
129
+ bottom: 0,
109
130
  });
110
131
 
111
132
  // Functions
112
133
  const adjustChartSize = () => {
113
- chartSize = null;
114
- const el = chartContainer;
115
- if (!el) return;
116
- const { width, height } = el.getBoundingClientRect();
117
- chartSize = { width: width - 5, height: height - 10 };
118
- console.log(chartSize);
134
+ chartSize = null;
135
+ const el = chartContainer;
136
+ if (!el) return;
137
+ const { width, height } = el.getBoundingClientRect();
138
+ chartSize = { width: width - 5, height: height - 10 };
139
+ console.log(chartSize);
119
140
  };
120
141
 
121
142
  const handleResize = () => {
122
- setTimeout(adjustChartSize, 300);
143
+ setTimeout(adjustChartSize, 300);
123
144
  };
124
145
 
125
146
  // Lifecycle hooks
126
147
  onMounted(() => {
127
- adjustChartSize();
128
- window.addEventListener("resize", handleResize);
148
+ adjustChartSize();
149
+ window.addEventListener('resize', handleResize);
129
150
  });
130
151
 
131
152
  onUnmounted(() => {
132
- window.removeEventListener("resize", handleResize);
153
+ window.removeEventListener('resize', handleResize);
133
154
  });
134
155
 
135
156
  // Style Configurations
136
157
  const dotStyling = (ctx: Record<string, any>) => ({
137
- r: ctx.active ? 5 : 1,
138
- fill: BRAND_COLOR,
158
+ r: ctx.active ? 5 : 1,
159
+ fill: BRAND_COLOR,
139
160
  });
140
161
  </script>
141
162
 
142
163
  <style>
143
164
  .chart-line {
144
- width: 100%;
145
- height: 300px;
165
+ width: 100%;
166
+ height: 300px;
146
167
  }
147
168
 
148
169
  [dir="rtl"] .chart-line {
149
- direction: ltr;
170
+ direction: ltr;
150
171
  }
151
172
 
152
- .chart-line .v-tooltip-content > div {
153
- border: none !important;
154
- border-radius: 6px !important;
155
- background-color: black !important;
156
- opacity: 0.7;
157
- padding: 0.5rem 1rem !important;
158
- box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06) !important;
159
- font-weight: 300;
173
+ .chart-line .v-tooltip-content>div {
174
+ border: none !important;
175
+ border-radius: 6px !important;
176
+ background-color: black !important;
177
+ opacity: 0.7;
178
+ padding: 0.5rem 1rem !important;
179
+ box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06) !important;
180
+ font-weight: 300;
160
181
  }
161
182
 
162
- .chart-line .v-tooltip-content > div b {
163
- font-weight: 400;
183
+ .chart-line .v-tooltip-content>div b {
184
+ font-weight: 400;
164
185
  }
165
186
 
166
187
  .layer-grid g:last-child {
167
- display: none;
188
+ display: none;
168
189
  }
169
190
 
170
191
  .layer-axis-x .tick:nth-child(2n + 1) {
171
- opacity: 0;
192
+ opacity: 0;
172
193
  }
173
194
 
174
195
  @media screen and (max-width: 910px) {
175
- .chart-line {
176
- height: 140px;
177
- }
178
-
179
- .layer-axis-x .tick {
180
- opacity: 0;
181
- font-size: 0;
182
- }
196
+ .chart-line {
197
+ height: 140px;
198
+ }
199
+
200
+ .layer-axis-x .tick {
201
+ opacity: 0;
202
+ font-size: 0;
203
+ }
183
204
  }
184
205
  </style>
@@ -0,0 +1,153 @@
1
+ <template>
2
+ <div class="datetime-wrap">
3
+ <div class="date-wrap">
4
+ <VDatepicker
5
+ inline
6
+ week-start="0"
7
+ v-model="selectedDate"
8
+ :highlight-week-days="[6]"
9
+ :enable-time-picker="false"
10
+ :month-change-on-scroll="false"
11
+ v-bind="options"
12
+ >
13
+ <template #action-buttons/>
14
+ <template #action-preview/>
15
+ </VDatepicker>
16
+ </div>
17
+ <div class="time-wrap" v-if="showTimeWrap">
18
+ <template v-for="hr in hours" :key="hr">
19
+ <input type="radio" :id="`${hr}_${name}`" :name="name" :value="hr" v-model="selectedHour" >
20
+ <label :for="`${hr}_${name}`">{{ hr }}</label>
21
+ </template>
22
+ </div>
23
+ </div>
24
+ </template>
25
+
26
+ <script setup lang="ts">
27
+ import VDatepicker from '@vuepic/vue-datepicker';
28
+ import '@vuepic/vue-datepicker/dist/main.css';
29
+
30
+ defineProps<{ name: string, options: Record<string, any>, showTimeWrap: boolean}>();
31
+ const selectedDate = $ref(null);
32
+ const selectedHour = $ref();
33
+
34
+ const hours = Array.from({ length: 18 }, (_, index) => {
35
+ const hour = Math.floor(index / 2) + 9;
36
+ const minute = index % 2 === 0 ? '00' : '30';
37
+ return `${hour}:${minute}`;
38
+ });
39
+ </script>
40
+ <style>
41
+ .datetime-wrap {
42
+ display: flex;
43
+ gap: 3rem;
44
+ padding: 1rem;
45
+ }
46
+
47
+ .time-wrap {
48
+ display: grid;
49
+ gap: 0.5rem;
50
+ grid-template-columns: 1fr 1fr;
51
+ width: 100%;
52
+ }
53
+
54
+ .time-wrap input {
55
+ display: none;
56
+ }
57
+
58
+ .time-wrap label {
59
+ background: var(--input-bg);
60
+ border-radius: var(--btn-border-radius);
61
+ line-height: calc(var(--btn-height) * 0.9);
62
+ display: block;
63
+ cursor: pointer;
64
+ transition: var(--bgl-transition);
65
+ text-align: center;
66
+ font-size: 16px;
67
+ color: var(--bgl-primary);
68
+ border: 1px solid var(--bgl-primary);
69
+ }
70
+
71
+ .time-wrap input[type="radio"]:checked+label {
72
+ background: var(--bgl-primary);
73
+ color: var(--bgl-white);
74
+ }
75
+
76
+ .time-wrap label:hover {
77
+ filter: var(--bgl-hover-filter);
78
+ }
79
+
80
+ .time-wrap label:active {
81
+ filter: var(--bgl-active-filter);
82
+ }
83
+
84
+ .dp__theme_light {
85
+ --dp-background-color: var(--bgl-white);
86
+ --dp-text-color: var(--bgl-black);
87
+ --dp-hover-color: var(--input-bg);
88
+ --dp-hover-text-color: var(--bgl-black);
89
+ --dp-hover-icon-color: var(--bgl-primary);
90
+ --dp-primary-color: var(--bgl-primary);
91
+ --dp-primary-disabled-color: var(--bgl-primary);
92
+ --dp-primary-text-color: var(--bgl-white);
93
+ --dp-secondary-color: var(--bgl-gray);
94
+ --dp-border-color: transparent;
95
+ --dp-menu-border-color: transparent;
96
+ --dp-scroll-bar-background: transparent;
97
+ --dp-scroll-bar-color: var(--bgl-gray);
98
+ --dp-icon-color: var(--bgl-gray);
99
+ --dp-highlight-color: var(--bgl-gray-light);
100
+ }
101
+
102
+ :root {
103
+ --dp-font-family: inherit;
104
+ --dp-cell-border-radius: 100%;
105
+ --dp-common-transition: all 200s ease-in;
106
+
107
+ --dp-cell-size: 40px;
108
+ /*Width and height of calendar cell*/
109
+ --dp-menu-min-width: 280px;
110
+ /*Adjust the min width of the menu*/
111
+ --dp-row-margin: 8px 0;
112
+ /*Adjust the spacing between rows in the calendar*/
113
+ }
114
+
115
+ .dp__calendar_header {
116
+ font-weight: 400;
117
+ padding: 10px 0 0;
118
+ margin-bottom: -10px;
119
+ }
120
+
121
+ .dp__calendar_row>div:last-child {
122
+ pointer-events: none;
123
+ }
124
+ .dp__outer_menu_wrap.dp--menu-wrapper{
125
+ filter: drop-shadow(0 0 20px var(--bgl-shadow));
126
+ }
127
+ .dp__input{
128
+ background: var(--input-bg);
129
+ border: none;
130
+ padding: 0.7rem;
131
+ border-radius: var(--input-border-radius);
132
+ color: var(--input-color);
133
+ min-width: calc(var(--input-height) * 3);
134
+ width: 100%;
135
+ }
136
+ .dp__input:focus-visible {
137
+ outline: none;
138
+ box-shadow: inset 0 0 10px #00000012;
139
+ }
140
+ @media screen and (max-width: 767px) {
141
+ .datetime-wrap {
142
+ flex-wrap: wrap;
143
+ padding: 0rem;
144
+ gap: 1rem;
145
+ justify-content: center;
146
+ }
147
+
148
+ :root {
149
+ --dp-menu-min-width: 200px;
150
+ --dp-cell-size: 35px;
151
+ }
152
+ }
153
+ </style>
@@ -20,3 +20,4 @@ export { default as Checkbox } from './Checkbox.vue';
20
20
  export { default as ColorPicker } from './ColorPicker.vue';
21
21
  export { default as DynamicLinkField } from './DynamicLinkField.vue';
22
22
  export { default as PlainText } from './PlainText.vue';
23
+ export { default as DatePicker } from './DatePicker.vue';
@@ -142,8 +142,8 @@ function animateCircle(e: DragEvent) {
142
142
 
143
143
  function emitValue() {
144
144
  // const fileValues = files.map((f) => f.serverFile?.id);
145
- // console.log({ files });
146
- if (!computedMultiple) return props.context?.node.input(files[0].serverFile);
145
+ const relationshipObjKey = props.context?.attrs?.relationshipObjKey;
146
+ if (!computedMultiple) return props.context?.node.input(relationshipObjKey ? files[0].serverFile.id : files[0].serverFile);
147
147
  // eslint-disable-next-line no-alert
148
148
  return alert('not implemented');
149
149
  }
@@ -202,14 +202,16 @@ async function addFiles(addedFiles: FileList) {
202
202
 
203
203
  onMounted(() => {
204
204
  dropZoneEl?.addEventListener('dragover', animateCircle);
205
- if (!computedMultiple && props.context?.value) {
205
+ const relationshipObjKey = props.context?.attrs?.relationshipObjKey;
206
+ const imageObj = relationshipObjKey ? props.context?.node?.parent?.value[relationshipObjKey] : props.context?.node?.value;
207
+ if (!computedMultiple && imageObj) {
206
208
  files.push({
207
- serverFile: props.context?.value,
209
+ serverFile: imageObj,
208
210
  uploaded: true,
209
211
  uploading: false,
210
212
  progress: 100,
211
- dataUrl: props.context?.value?.url,
212
- name: props.context?.value?.name,
213
+ dataUrl: imageObj?.url,
214
+ name: imageObj?.name,
213
215
  });
214
216
  }
215
217
  });