mountain-ui 1.0.100 → 1.0.102

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": "mountain-ui",
3
3
  "private": false,
4
- "version": "1.0.100",
4
+ "version": "1.0.102",
5
5
  "description": "A comprehensive UI component library for ERP systems with field types, entities, and registry management built with Svelte",
6
6
  "type": "module",
7
7
  "module": "index.js",
@@ -10,6 +10,7 @@
10
10
  let {
11
11
  settingsHref = '',
12
12
  reportHref = '',
13
+ hubHref = '',
13
14
  guideHref = '',
14
15
  logoutHref = '',
15
16
  getProjectHref
@@ -46,7 +47,7 @@
46
47
  function handleLogout() {
47
48
  logout();
48
49
 
49
- window.location.href = logoutHref
50
+ window.location.href = logoutHref;
50
51
  }
51
52
  </script>
52
53
 
@@ -83,6 +84,7 @@
83
84
  fill="#292D32"
84
85
  />
85
86
  </svg>
87
+
86
88
  <h5>Paramètres</h5>
87
89
  </Button>
88
90
  <span class="separator"></span>
@@ -139,6 +141,41 @@
139
141
  <h5>Guide</h5>
140
142
  </Button>
141
143
  <span class="separator"></span>
144
+ {#if hubHref}
145
+ <Button href={hubHref} variant="ghost" style="width:100%;">
146
+ <svg
147
+ width="24"
148
+ height="24"
149
+ viewBox="0 0 24 24"
150
+ fill="none"
151
+ xmlns="http://www.w3.org/2000/svg"
152
+ >
153
+ <path
154
+ d="M12 22.75C6.07 22.75 1.25 17.93 1.25 12C1.25 6.07 6.07 1.25 12 1.25C17.93 1.25 22.75 6.07 22.75 12C22.75 17.93 17.93 22.75 12 22.75ZM12 2.75C6.9 2.75 2.75 6.9 2.75 12C2.75 17.1 6.9 21.25 12 21.25C17.1 21.25 21.25 17.1 21.25 12C21.25 6.9 17.1 2.75 12 2.75Z"
155
+ fill="#292D32"
156
+ />
157
+ <path
158
+ d="M9.00023 21.75H8.00023C7.59023 21.75 7.25023 21.41 7.25023 21C7.25023 20.59 7.57023 20.26 7.98023 20.25C6.41023 14.89 6.41023 9.11 7.98023 3.75C7.57023 3.74 7.25023 3.41 7.25023 3C7.25023 2.59 7.59023 2.25 8.00023 2.25H9.00023C9.24023 2.25 9.47023 2.37 9.61023 2.56C9.75023 2.76 9.79023 3.01 9.71023 3.24C7.83023 8.89 7.83023 15.11 9.71023 20.77C9.79023 21 9.75023 21.25 9.61023 21.45C9.47023 21.63 9.24023 21.75 9.00023 21.75Z"
159
+ fill="#292D32"
160
+ />
161
+ <path
162
+ d="M15.0004 21.7502C14.9204 21.7502 14.8404 21.7402 14.7604 21.7102C14.3704 21.5802 14.1504 21.1502 14.2904 20.7602C16.1704 15.1102 16.1704 8.89018 14.2904 3.23018C14.1604 2.84018 14.3704 2.41018 14.7604 2.28018C15.1604 2.15018 15.5804 2.36018 15.7104 2.75018C17.7004 8.71018 17.7004 15.2702 15.7104 21.2202C15.6104 21.5502 15.3104 21.7502 15.0004 21.7502Z"
163
+ fill="#292D32"
164
+ />
165
+ <path
166
+ d="M12 17.1998C9.21 17.1998 6.43 16.8098 3.75 16.0198C3.74 16.4198 3.41 16.7498 3 16.7498C2.59 16.7498 2.25 16.4098 2.25 15.9998V14.9998C2.25 14.7598 2.37 14.5298 2.56 14.3898C2.76 14.2498 3.01 14.2098 3.24 14.2898C8.89 16.1698 15.12 16.1698 20.77 14.2898C21 14.2098 21.25 14.2498 21.45 14.3898C21.65 14.5298 21.76 14.7598 21.76 14.9998V15.9998C21.76 16.4098 21.42 16.7498 21.01 16.7498C20.6 16.7498 20.27 16.4298 20.26 16.0198C17.57 16.8098 14.79 17.1998 12 17.1998Z"
167
+ fill="#292D32"
168
+ />
169
+ <path
170
+ d="M20.9998 9.74986C20.9198 9.74986 20.8398 9.73986 20.7598 9.70986C15.1098 7.82986 8.87978 7.82986 3.22978 9.70986C2.82978 9.83986 2.40978 9.62986 2.27978 9.23986C2.15978 8.83986 2.36978 8.41986 2.75978 8.28986C8.71978 6.29986 15.2798 6.29986 21.2298 8.28986C21.6198 8.41986 21.8398 8.84986 21.6998 9.23986C21.6098 9.54986 21.3098 9.74986 20.9998 9.74986Z"
171
+ fill="#292D32"
172
+ />
173
+ </svg>
174
+
175
+ <h5>Retourner au hub</h5>
176
+ </Button>
177
+ <span class="separator"></span>
178
+ {/if}
142
179
  <Button variant="ghost" style="width:100%;" onClick={handleLogout}>
143
180
  <svg
144
181
  width="24"
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import { Portal } from 'hamzus-ui';
3
3
  import { navigationRegistry } from '../registry.svelte';
4
+ import { page } from '$app/stores';
4
5
 
5
6
  let { text, href } = $props();
6
7
 
@@ -65,11 +66,13 @@
65
66
  window.removeEventListener('scroll', update, true);
66
67
  };
67
68
  });
69
+
68
70
  </script>
69
71
 
70
72
  <a
71
73
  {href}
72
74
  class="btn"
75
+ class:active={href === $page.url.pathname}
73
76
  bind:this={btn}
74
77
  onmouseenter={() => {
75
78
  isHovered = true;
@@ -112,12 +115,17 @@
112
115
  position: relative;
113
116
  cursor: pointer;
114
117
  overflow: clip;
118
+ transition: background-color .2s ease-out;
115
119
  }
116
120
 
117
121
  .btn:hover {
118
122
  background-color: var(--bg-blur);
119
123
  }
120
124
 
125
+ .btn.active {
126
+ background-color: var(--bg-2);
127
+ }
128
+
121
129
  .btn h5 {
122
130
  white-space: nowrap;
123
131
  /* overflow: hidden; */