@functionalcms/svelte-components 2.1.10 → 2.1.11

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.
@@ -6,6 +6,7 @@ $:
6
6
  css ? css : ""
7
7
  ].filter((c) => c).join(" ");
8
8
  </script>
9
+
9
10
  <style>
10
11
  div {
11
12
  background: var(--functional-banner-background);
@@ -1,21 +1,4 @@
1
- <script>import { Visiblity } from "../../Visiblity";
2
- import { HeaderNavigationItem } from "../../HeaderNavigationItem";
3
- import { afterNavigate } from "$app/navigation";
4
- import { page } from "$app/stores";
5
- export let pages = [];
6
- export let authentication = false;
7
- export let css = "";
8
- const selectVisible = (pages2, visiblity) => pages2.filter(
9
- (page2) => page2?.visiblity === Visiblity.Always || page2?.visiblity === visiblity
10
- );
11
- $:
12
- visibility = authentication ? Visiblity.Authenticated : Visiblity.NotAuthenticated;
13
- $:
14
- visibleNavItems = selectVisible(pages, visibility);
15
- $:
16
- selected = false;
17
- afterNavigate((navigation) => selected = false);
18
- </script>
1
+
19
2
  <style>
20
3
  nav > ul {
21
4
  margin: var(--functional-menu-margin, 'auto');
@@ -99,6 +82,24 @@ afterNavigate((navigation) => selected = false);
99
82
  }
100
83
  </style>
101
84
 
85
+ <script>import { Visiblity, HeaderNavigationItem } from "./Menu.js";
86
+ import { afterNavigate } from "$app/navigation";
87
+ import { page } from "$app/stores";
88
+ export let pages = [];
89
+ export let authentication = false;
90
+ export let css = "";
91
+ const selectVisible = (pages2, visiblity) => pages2.filter(
92
+ (page2) => page2?.visiblity === Visiblity.Always || page2?.visiblity === visiblity
93
+ );
94
+ $:
95
+ visibility = authentication ? Visiblity.Authenticated : Visiblity.NotAuthenticated;
96
+ $:
97
+ visibleNavItems = selectVisible(pages, visibility);
98
+ $:
99
+ selected = false;
100
+ afterNavigate((navigation) => selected = false);
101
+ </script>
102
+
102
103
  <nav class={css}>
103
104
  <label for="id-show-menu" class="show-menu">
104
105
  <div class="nav-icon">
@@ -1,4 +1,5 @@
1
1
  import { SvelteComponent } from "svelte";
2
+ import { HeaderNavigationItem } from './Menu.js';
2
3
  declare const __propDef: {
3
4
  props: {
4
5
  pages?: HeaderNavigationItem[] | undefined;
@@ -1,8 +1,4 @@
1
1
  <style>
2
- .sticky {
3
- display: block;
4
- position: absolute;
5
- }
6
2
  :global(.no-border) {
7
3
  border: none!important;;
8
4
  }
@@ -57,6 +53,7 @@ const klasses = [
57
53
  noBorder ? "no-border" : ""
58
54
  ].filter((c) => c).join(" ");
59
55
  </script>
56
+
60
57
  <Button
61
58
  type="button"
62
59
  data-a11y-dialog-show="drawer-start-test"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@functionalcms/svelte-components",
3
- "version": "2.1.10",
3
+ "version": "2.1.11",
4
4
  "scripts": {
5
5
  "dev": "vite dev",
6
6
  "build": "vite build && npm run package",
@@ -15,7 +15,8 @@
15
15
  "types": "./dist/index.d.ts",
16
16
  "svelte": "./dist/index.js"
17
17
  },
18
- "./dist/css/properties.css": "./css/properties.css",
18
+ "./dist/css/properties.css": "./dist/css/properties.css",
19
+ "./css/properties.css": "./dist/css/properties.css",
19
20
  "./package.json": "./package.json"
20
21
  },
21
22
  "files": [