@bagelink/vue 1.12.23 → 1.12.25

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@bagelink/vue",
3
3
  "type": "module",
4
- "version": "1.12.23",
4
+ "version": "1.12.25",
5
5
  "description": "Bagel core sdk packages",
6
6
  "author": {
7
7
  "name": "Bagel Studio",
@@ -90,7 +90,7 @@
90
90
  "signature_pad": "^5.0.9",
91
91
  "vue-i18n": "^11.2.8",
92
92
  "vue-toastification": "^2.0.0-rc.5",
93
- "@bagelink/utils": "1.12.23"
93
+ "@bagelink/utils": "1.12.25"
94
94
  },
95
95
  "scripts": {
96
96
  "dev": "tsx watch src/index.ts",
@@ -412,4 +412,14 @@ tbody tr {
412
412
  tbody tr:hover {
413
413
  background: var(--bgl-gray-light);
414
414
  }
415
+
416
+ @media (max-width: 910px) {
417
+ .col {
418
+ max-width: 60vw !important;
419
+ }
420
+ .max-col-width {
421
+ max-width: 60vw !important;
422
+ }
423
+ }
424
+
415
425
  </style>
@@ -4,15 +4,17 @@ import { ref, provide, onMounted, onUnmounted, computed } from 'vue'
4
4
  interface Props {
5
5
  sidebarWidth?: string
6
6
  sidebarCardStyle?: boolean
7
+ defaultOpen?: boolean
7
8
  }
8
9
 
9
10
  const props = withDefaults(defineProps<Props>(), {
10
11
  sidebarWidth: '260px',
11
- sidebarCardStyle: false
12
+ sidebarCardStyle: false,
13
+ defaultOpen: true,
12
14
  })
13
15
 
14
16
  // Menu state
15
- const isOpen = ref(true)
17
+ const isOpen = ref(props.defaultOpen)
16
18
  const isMobile = ref(false)
17
19
 
18
20
  // Check if mobile
@@ -7,7 +7,7 @@ import { resolveI18n } from '../../i18n'
7
7
 
8
8
  // Extended interface for links with active route tracking
9
9
  interface LinkWithAction extends NavLink {
10
- activeRoutes?: string[] // נתיבים שצריכים להיות מסומנים כאקטיביים עבור הלינק הזה
10
+ activeRoutes?: string[] // Routes that should be marked as active for this link
11
11
  }
12
12
 
13
13
  interface Props {
@@ -23,10 +23,14 @@ interface Props {
23
23
  name?: string
24
24
  frame?: boolean
25
25
  activeRoutes?: string[]
26
+ centerlinks?: boolean
27
+ defaultOpen?: boolean
26
28
  }
27
29
 
28
30
  const props = withDefaults(defineProps<Props>(), {
29
31
  card: true,
32
+ centerlinks: false,
33
+ defaultOpen: true,
30
34
  bgColor: 'var(--bgl-white)',
31
35
  textColor: 'var(--bgl-black)',
32
36
  activeColor: 'var(--bgl-black)',
@@ -40,9 +44,12 @@ const route = useRoute()
40
44
  const isTransitioning = ref(false)
41
45
 
42
46
  // Inject menu state from parent
47
+ const _fallbackIsOpen = ref(props.defaultOpen)
48
+ const _fallbackIsMobile = ref(false)
49
+
43
50
  const menuState = inject('menuState', {
44
- isOpen: { value: true },
45
- isMobile: { value: false },
51
+ isOpen: _fallbackIsOpen,
52
+ isMobile: _fallbackIsMobile,
46
53
  closeOnMobile: () => void 0,
47
54
  sidebarWidth: '260px',
48
55
  sidebarCollapsedWidth: '66px',
@@ -160,7 +167,7 @@ const sidebarStyles = computed(() => {
160
167
  >
161
168
  <!-- Logo/Brand -->
162
169
  <router-link
163
- to="/" class="decoration-none flex px-05" :class="{
170
+ to="/" class="decoration-none flex siderbarLogoWrap" :class="{
164
171
  'gap-05': menuState.isOpen.value,
165
172
  'gap-0': !menuState.isOpen.value,
166
173
  }"
@@ -175,7 +182,7 @@ const sidebarStyles = computed(() => {
175
182
  </router-link>
176
183
 
177
184
  <!-- Navigation Links -->
178
- <nav class="sidebar-nav flex column flex-stretch gap-025 align-items-start scrollbar-gutter-stable">
185
+ <nav class="sidebar-nav flex column flex-stretch gap-025 align-items-start scrollbar-gutter-stable" :class="{ 'justify-content-center': props.centerlinks }">
179
186
  <Btn
180
187
  v-for="link in props.navLinks" :key="link.to"
181
188
  :title="!menuState.isOpen.value && !menuState.isMobile.value ? resolveI18n(link.label) : ''" fullWidth
@@ -183,7 +190,8 @@ const sidebarStyles = computed(() => {
183
190
  :style="{
184
191
  backgroundColor: isActiveRoute(link) ? props.activeColor : props.bgColor,
185
192
  color: isActiveRoute(link) ? 'white' : props.textColor,
186
- }" :to="link.to || '/'" @click="link.action"
193
+ }"
194
+ :to="link.to || '/'" @click="link.action"
187
195
  >
188
196
  <Icon :name="link.icon" size="1.2" />
189
197
  <span class="nav-text">
@@ -196,8 +204,13 @@ const sidebarStyles = computed(() => {
196
204
  <!-- Footer Links -->
197
205
  <Btn
198
206
  v-for="link in props.footerLinks" :key="link.to || link.label"
199
- :title="!menuState.isOpen.value && !menuState.isMobile.value ? resolveI18n(link.label) : ''" alignTxt="start"
200
- fullWidth flat :icon="link.icon" class="flex-shrink-0 px-1" :to="link.to" @click="link.action"
207
+ :title="!menuState.isOpen.value && !menuState.isMobile.value ? resolveI18n(link.label) : ''"
208
+ :style="{
209
+ color: isActiveRoute(link) ? 'white' : props.textColor,
210
+ }"
211
+ fullWidth
212
+ alignTxt="start"
213
+ flat :icon="link.icon" class="flex-shrink-0 px-1" :to="link.to" @click="link.action"
201
214
  >
202
215
  <span class="nav-text">
203
216
  {{ resolveI18n(link.label) }}
@@ -243,6 +243,7 @@
243
243
  "reorderSaving": "Saving order..."
244
244
  },
245
245
  "datastores": {
246
+ "selectCollection": "Select a collection from the list",
246
247
  "fieldName": "Name",
247
248
  "fieldStore": "Store",
248
249
  "fieldStoreHint": "e.g.: default",
@@ -264,6 +264,7 @@
264
264
  "reorderSaving": "שומר סדר..."
265
265
  },
266
266
  "datastores": {
267
+ "selectCollection": "בחרו קולקציה מהרשימה",
267
268
  "fieldName": "שם",
268
269
  "fieldStore": "Store",
269
270
  "fieldStoreHint": "לדוגמה: default",
@@ -89,10 +89,6 @@
89
89
  border: 1px solid var(--border-color);
90
90
  }
91
91
 
92
- .border-primary {
93
- border: 1px solid var(--bgl-primary);
94
- }
95
-
96
92
  .outline {
97
93
  outline: 1px solid var(--border-color);
98
94
  }
@@ -198,7 +198,8 @@
198
198
  }
199
199
 
200
200
  .justify-content,
201
- .justify-content-center {
201
+ .justify-content-center,
202
+ .justify-center {
202
203
  justify-content: center;
203
204
  }
204
205
 
@@ -226,7 +227,8 @@
226
227
  align-items: flex-start !important;
227
228
  }
228
229
 
229
- .align-items-center {
230
+ .align-items-center,
231
+ .align-center {
230
232
  align-items: center !important;
231
233
  }
232
234
 
@@ -3364,6 +3366,46 @@
3364
3366
  height: 10px !important;
3365
3367
  }
3366
3368
 
3369
+ .max-h-10p {
3370
+ max-height: 10%;
3371
+ }
3372
+
3373
+ .max-h-20p {
3374
+ max-height: 20%;
3375
+ }
3376
+
3377
+ .max-h-30p {
3378
+ max-height: 30%;
3379
+ }
3380
+
3381
+ .max-h-40p {
3382
+ max-height: 40%;
3383
+ }
3384
+
3385
+ .max-h-50p {
3386
+ max-height: 50%;
3387
+ }
3388
+
3389
+ .max-h-60p {
3390
+ max-height: 60%;
3391
+ }
3392
+
3393
+ .max-h-70p {
3394
+ max-height: 70%;
3395
+ }
3396
+
3397
+ .max-h-80p {
3398
+ max-height: 80%;
3399
+ }
3400
+
3401
+ .max-h-90p {
3402
+ max-height: 90%;
3403
+ }
3404
+
3405
+ .max-h-100p {
3406
+ max-height: 100%;
3407
+ }
3408
+
3367
3409
  .hm-10px,
3368
3410
  .max-h-10px,
3369
3411
  .h-max-10px,
@@ -3651,6 +3693,10 @@
3651
3693
  max-height: 100px;
3652
3694
  }
3653
3695
 
3696
+ .max-h-100p {
3697
+ max-height: 100%;
3698
+ }
3699
+
3654
3700
  .hm-100vh,
3655
3701
  .max-h-100vh,
3656
3702
  .h-max-100vh,
@@ -2609,6 +2609,47 @@
2609
2609
  height: 10vh !important;
2610
2610
  }
2611
2611
 
2612
+
2613
+ .m_max-h-10p {
2614
+ max-height: 10%;
2615
+ }
2616
+
2617
+ .m_max-h-20p {
2618
+ max-height: 20%;
2619
+ }
2620
+
2621
+ .m_max-h-30p {
2622
+ max-height: 30%;
2623
+ }
2624
+
2625
+ .m_max-h-40p {
2626
+ max-height: 40%;
2627
+ }
2628
+
2629
+ .m_max-h-50p {
2630
+ max-height: 50%;
2631
+ }
2632
+
2633
+ .m_max-h-60p {
2634
+ max-height: 60%;
2635
+ }
2636
+
2637
+ .m_max-h-70p {
2638
+ max-height: 70%;
2639
+ }
2640
+
2641
+ .m_max-h-80p {
2642
+ max-height: 80%;
2643
+ }
2644
+
2645
+ .m_max-h-90p {
2646
+ max-height: 90%;
2647
+ }
2648
+
2649
+ .m_max-h-100p {
2650
+ max-height: 100%;
2651
+ }
2652
+
2612
2653
  .m_h-10px,
2613
2654
  .m_h10px {
2614
2655
  height: 10px !important;
@@ -530,7 +530,7 @@ export function column<T = any, P extends Path<T, PO> = any, PO extends PathsOpt
530
530
  return {
531
531
  $el: 'div',
532
532
  id,
533
- class: options?.class ?? 'column-class',
533
+ class: options?.class ?? 'column-class ellipsis-1 line-height-15',
534
534
  vIf: options?.vIf,
535
535
  style: options?.style,
536
536
  transform: options?.transform,