@apptegy/nuxt-navigation 0.1.72 → 0.1.73

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/module.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "nuxt": ">=3.0.0"
5
5
  },
6
6
  "configKey": "@apptegy/nuxt-navigation",
7
- "version": "0.1.72",
7
+ "version": "0.1.73",
8
8
  "builder": {
9
9
  "@nuxt/module-builder": "1.0.1",
10
10
  "unbuild": "unknown"
@@ -0,0 +1,3 @@
1
+ <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M2.66669 8H13.3334M2.66669 4H13.3334M2.66669 12H13.3334" stroke="#2D2D2D" stroke-width="1.25" stroke-linecap="round" stroke-linejoin="round"/>
3
+ </svg>
@@ -0,0 +1,10 @@
1
+ <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <g clip-path="url(#clip0_2001_18302)">
3
+ <path d="M7.99998 11.3333V14.6667M9.99998 6.22666V4.66666C9.99998 4.48985 10.0702 4.32028 10.1952 4.19526C10.3203 4.07023 10.4898 3.99999 10.6666 3.99999C11.0203 3.99999 11.3594 3.85952 11.6095 3.60947C11.8595 3.35942 12 3.02028 12 2.66666C12 2.31304 11.8595 1.9739 11.6095 1.72385C11.3594 1.4738 11.0203 1.33333 10.6666 1.33333H5.25998M1.33331 1.33333L14.6666 14.6667M5.99998 6V7.17333C5.99985 7.42138 5.93052 7.66449 5.79979 7.8753C5.66907 8.08611 5.48212 8.25628 5.25998 8.36666L4.07331 8.96666C3.85117 9.07705 3.66423 9.24721 3.5335 9.45803C3.40277 9.66884 3.33344 9.91194 3.33331 10.16V10.6667C3.33331 10.8435 3.40355 11.013 3.52858 11.1381C3.6536 11.2631 3.82317 11.3333 3.99998 11.3333H11.3333" stroke="#2D2D2D" stroke-width="1.25" stroke-linecap="round" stroke-linejoin="round"/>
4
+ </g>
5
+ <defs>
6
+ <clipPath id="clip0_2001_18302">
7
+ <rect width="16" height="16" fill="white"/>
8
+ </clipPath>
9
+ </defs>
10
+ </svg>
@@ -0,0 +1,3 @@
1
+ <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M7.99998 11.3334V14.6667M5.99998 7.17337C5.99985 7.42143 5.93052 7.66453 5.79979 7.87534C5.66907 8.08616 5.48212 8.25632 5.25998 8.36671L4.07331 8.96671C3.85117 9.07709 3.66423 9.24726 3.5335 9.45807C3.40277 9.66888 3.33344 9.91198 3.33331 10.16V10.6667C3.33331 10.8435 3.40355 11.0131 3.52858 11.1381C3.6536 11.2631 3.82317 11.3334 3.99998 11.3334H12C12.1768 11.3334 12.3464 11.2631 12.4714 11.1381C12.5964 11.0131 12.6666 10.8435 12.6666 10.6667V10.16C12.6665 9.91198 12.5972 9.66888 12.4665 9.45807C12.3357 9.24726 12.1488 9.07709 11.9266 8.96671L10.74 8.36671C10.5178 8.25632 10.3309 8.08616 10.2002 7.87534C10.0694 7.66453 10.0001 7.42143 9.99998 7.17337V4.66671C9.99998 4.4899 10.0702 4.32033 10.1952 4.1953C10.3203 4.07028 10.4898 4.00004 10.6666 4.00004C11.0203 4.00004 11.3594 3.85957 11.6095 3.60952C11.8595 3.35947 12 3.02033 12 2.66671C12 2.31309 11.8595 1.97395 11.6095 1.7239C11.3594 1.47385 11.0203 1.33337 10.6666 1.33337H5.33331C4.97969 1.33337 4.64055 1.47385 4.3905 1.7239C4.14046 1.97395 3.99998 2.31309 3.99998 2.66671C3.99998 3.02033 4.14046 3.35947 4.3905 3.60952C4.64055 3.85957 4.97969 4.00004 5.33331 4.00004C5.51012 4.00004 5.67969 4.07028 5.80472 4.1953C5.92974 4.32033 5.99998 4.4899 5.99998 4.66671V7.17337Z" stroke="#2D2D2D" stroke-width="1.25" stroke-linecap="round" stroke-linejoin="round"/>
3
+ </svg>
@@ -36,11 +36,11 @@
36
36
  </slot>
37
37
  </NuxtLink>
38
38
  <div v-if="!isMobile && showCollapseButton">
39
- <button v-if="lockedExpanded && !allowCollapse" class="hamburger-button" @click="closeSidebar">
40
- <a-icon icon="24:hamburger" />
39
+ <button v-if="lockedExpanded && !allowCollapse && expanded" class="hamburger-button" @click="closeSidebar" v-tooltip.bottom="'Unpin menu'">
40
+ <img src="locked-pin.svg" id="locked-pin" />
41
41
  </button>
42
- <button v-if="!lockedExpanded && allowCollapse && expanded" class="hamburger-button" @click="lockSidebar">
43
- <a-icon icon="24:lock-unlocked" />
42
+ <button v-if="!lockedExpanded && allowCollapse && expanded" class="hamburger-button" @click="lockSidebar" v-tooltip.bottom="'Pin menu open'">
43
+ <img src="unlocked-pin.svg" id="unlocked-pin" />
44
44
  </button>
45
45
  <button v-if="!lockedExpanded && allowCollapse && !expanded" class="hamburger-button">
46
46
  <a-icon icon="24:hamburger" />
@@ -133,6 +133,13 @@ const allowCollapse = ref(false);
133
133
  watch(expanded, (value) => {
134
134
  emit("toggle-expand", value ? 264 : 64);
135
135
  });
136
+ watch(isMobile, (value) => {
137
+ if (value) {
138
+ expanded.value = true;
139
+ lockedExpanded.value = true;
140
+ allowCollapse.value = false;
141
+ }
142
+ }, { immediate: true });
136
143
  function onHover() {
137
144
  if (!expanded.value) {
138
145
  expanded.value = true;
@@ -311,4 +318,12 @@ function lockSidebar() {
311
318
  height: 24px;
312
319
  width: 24px;
313
320
  }
321
+ .navbar #unlocked-pin {
322
+ width: 16px;
323
+ height: 16px;
324
+ }
325
+ .navbar #locked-pin {
326
+ width: 16px;
327
+ height: 16px;
328
+ }
314
329
  </style>
@@ -21,15 +21,15 @@ interface ISidebarProps {
21
21
  schoolWebsite: string;
22
22
  showCollapseButton?: boolean;
23
23
  }
24
- declare var __VLS_6: {}, __VLS_28: {}, __VLS_35: {}, __VLS_47: {};
24
+ declare var __VLS_6: {}, __VLS_18: {}, __VLS_25: {}, __VLS_37: {};
25
25
  type __VLS_Slots = {} & {
26
26
  logo?: (props: typeof __VLS_6) => any;
27
27
  } & {
28
- switcher?: (props: typeof __VLS_28) => any;
28
+ switcher?: (props: typeof __VLS_18) => any;
29
29
  } & {
30
- default?: (props: typeof __VLS_35) => any;
30
+ default?: (props: typeof __VLS_25) => any;
31
31
  } & {
32
- logo?: (props: typeof __VLS_47) => any;
32
+ logo?: (props: typeof __VLS_37) => any;
33
33
  };
34
34
  declare const __VLS_component: import("vue").DefineComponent<ISidebarProps, void, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
35
35
  "toggle-expand": (width: number) => any;
@@ -13,10 +13,7 @@ const component = computed(() => props.as || resolveComponent("NuxtLink"));
13
13
  <template>
14
14
  <component :is="component" class="a-navbar-item" :class="{ expanded, active, collapsed: !expanded }">
15
15
  <slot name="icon">
16
- <a-tooltip v-if="!expanded" :label="name" position="right" size="small">
17
- <a-icon class="icon" :icon="icon" font-size="24px"/>
18
- </a-tooltip>
19
- <a-icon v-else class="icon" :icon="icon" font-size="24px"/>
16
+ <a-icon class="icon" :icon="icon" font-size="24px"/>
20
17
  </slot>
21
18
  <slot v-if="expanded" />
22
19
  </component>
@@ -4,11 +4,11 @@ type __VLS_Props = {
4
4
  as?: string;
5
5
  name?: string;
6
6
  };
7
- declare var __VLS_7: {}, __VLS_24: {};
7
+ declare var __VLS_7: {}, __VLS_14: {};
8
8
  type __VLS_Slots = {} & {
9
9
  icon?: (props: typeof __VLS_7) => any;
10
10
  } & {
11
- default?: (props: typeof __VLS_24) => any;
11
+ default?: (props: typeof __VLS_14) => any;
12
12
  };
13
13
  declare const __VLS_component: import("vue").DefineComponent<__VLS_Props, void, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
14
14
  declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@apptegy/nuxt-navigation",
3
- "version": "0.1.72",
3
+ "version": "0.1.73",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {
@@ -46,5 +46,5 @@
46
46
  "vue": "^3.5.13",
47
47
  "vue-tsc": "^3.0.3"
48
48
  },
49
- "gitHead": "b381569b223be75c0eb38f277ed0f07285970745"
49
+ "gitHead": "0d43db150f08a6db5f2778ebcb3dc8e439c05a3c"
50
50
  }