accomadesc 0.4.32 → 0.4.33
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/PageComponent.svelte +1 -30
- package/dist/PageComponent.svelte.d.ts +1 -1
- package/dist/PhotoGallery.svelte +6 -1
- package/dist/SiteState.svelte.d.ts +0 -2
- package/dist/SiteState.svelte.js +0 -2
- package/dist/style.d.ts +0 -1
- package/dist/style.js +0 -1
- package/dist/types.d.ts +0 -2
- package/package.json +1 -1
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
import { fade } from 'svelte/transition';
|
|
15
15
|
import Icon from './basic/Icon.svelte';
|
|
16
16
|
import { page } from '$app/state';
|
|
17
|
-
import Button from './basic/Button.svelte';
|
|
18
17
|
import { fallbackCSS } from './style.js';
|
|
19
18
|
import { GLOBAL_STATE, GlobalState } from './state.svelte';
|
|
20
19
|
import { setContext, untrack } from 'svelte';
|
|
@@ -28,7 +27,6 @@
|
|
|
28
27
|
content,
|
|
29
28
|
nav,
|
|
30
29
|
css,
|
|
31
|
-
selectedTheme = $bindable('light'),
|
|
32
30
|
showFooter = true,
|
|
33
31
|
footerRef = 'footer_html',
|
|
34
32
|
fixedHamburger = true,
|
|
@@ -65,10 +63,8 @@
|
|
|
65
63
|
|
|
66
64
|
let theme = $state(fallbackCSS.themes.light);
|
|
67
65
|
$effect(() => {
|
|
68
|
-
if (!!css
|
|
66
|
+
if (!!css) {
|
|
69
67
|
theme = css?.themes.light;
|
|
70
|
-
} else if (!!css && selectedTheme == 'dark') {
|
|
71
|
-
theme = css?.themes.dark;
|
|
72
68
|
}
|
|
73
69
|
});
|
|
74
70
|
|
|
@@ -115,16 +111,6 @@
|
|
|
115
111
|
</div>
|
|
116
112
|
{/snippet}
|
|
117
113
|
|
|
118
|
-
{#snippet themeswitcher()}
|
|
119
|
-
<div class="theme" class:hero={!!hero} class:ham={!!hero && !navbarOverHamburger}>
|
|
120
|
-
{#if selectedTheme == 'light'}
|
|
121
|
-
<Button iconName="moon" clicked={() => (selectedTheme = 'dark')} />
|
|
122
|
-
{:else}
|
|
123
|
-
<Button iconName="sun" clicked={() => (selectedTheme = 'light')} />
|
|
124
|
-
{/if}
|
|
125
|
-
</div>
|
|
126
|
-
{/snippet}
|
|
127
|
-
|
|
128
114
|
<div class="page-wrapper" bind:clientWidth={pageWidth} style={theme}>
|
|
129
115
|
{#if hero}
|
|
130
116
|
<header class="hero-image">
|
|
@@ -219,24 +205,9 @@
|
|
|
219
205
|
{/each}
|
|
220
206
|
</fieldset>
|
|
221
207
|
{/if}
|
|
222
|
-
{@render themeswitcher()}
|
|
223
208
|
</div>
|
|
224
209
|
|
|
225
210
|
<style>
|
|
226
|
-
.theme {
|
|
227
|
-
position: absolute;
|
|
228
|
-
top: 7rem;
|
|
229
|
-
right: 0.5rem;
|
|
230
|
-
}
|
|
231
|
-
|
|
232
|
-
.theme.hero {
|
|
233
|
-
top: 0.5rem;
|
|
234
|
-
}
|
|
235
|
-
|
|
236
|
-
.theme.hero.ham {
|
|
237
|
-
left: 0.5rem;
|
|
238
|
-
}
|
|
239
|
-
|
|
240
211
|
div.section-wrapper {
|
|
241
212
|
margin-bottom: 2rem;
|
|
242
213
|
width: 100%;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type PageProps, type I18nFacade } from './types.js';
|
|
2
2
|
type $$ComponentProps = PageProps & I18nFacade;
|
|
3
|
-
declare const PageComponent: import("svelte").Component<$$ComponentProps, {}, "
|
|
3
|
+
declare const PageComponent: import("svelte").Component<$$ComponentProps, {}, "">;
|
|
4
4
|
type PageComponent = ReturnType<typeof PageComponent>;
|
|
5
5
|
export default PageComponent;
|
package/dist/PhotoGallery.svelte
CHANGED
|
@@ -24,8 +24,13 @@
|
|
|
24
24
|
let galleryContainer: HTMLDivElement | undefined = $state();
|
|
25
25
|
|
|
26
26
|
let width = $state(1000);
|
|
27
|
+
// At least one column: a grid width wider than the container means a
|
|
28
|
+
// single-column gallery, never a zero-column (invisible) grid.
|
|
27
29
|
let numberOfCols = $derived(
|
|
28
|
-
Math.
|
|
30
|
+
Math.max(
|
|
31
|
+
1,
|
|
32
|
+
Math.floor(width / (gridPhotoWidth && Number.isInteger(gridPhotoWidth) ? gridPhotoWidth : 300)),
|
|
33
|
+
),
|
|
29
34
|
);
|
|
30
35
|
|
|
31
36
|
// Initial zoom only: later prop changes must not yank the viewer.
|
|
@@ -21,8 +21,6 @@ export declare class SiteState implements I18nFacade {
|
|
|
21
21
|
get calendarTranslation(): OccuplanTranslations;
|
|
22
22
|
get cookieTranslation(): CookieTranslation;
|
|
23
23
|
get formats(): Record<string, FormatSpec>;
|
|
24
|
-
selectedTheme: 'light' | 'dark';
|
|
25
|
-
selectedThemeInitialized: boolean;
|
|
26
24
|
constructor(getSiteConfig: () => SiteConfig, lang: string | undefined, defaultFormats?: Record<string, FormatSpec>);
|
|
27
25
|
updateCurrentLang: (lang: string) => string;
|
|
28
26
|
translateFunc: (ref: string) => string;
|
package/dist/SiteState.svelte.js
CHANGED
|
@@ -48,8 +48,6 @@ export class SiteState {
|
|
|
48
48
|
return this._getSiteConfigFn().lang.formats;
|
|
49
49
|
}
|
|
50
50
|
#defaultFormats;
|
|
51
|
-
selectedTheme = $state('light');
|
|
52
|
-
selectedThemeInitialized = $state(false);
|
|
53
51
|
constructor(getSiteConfig, lang, defaultFormats) {
|
|
54
52
|
this._getSiteConfigFn = getSiteConfig;
|
|
55
53
|
this.#defaultFormats = defaultFormats;
|
package/dist/style.d.ts
CHANGED
package/dist/style.js
CHANGED
|
@@ -2,6 +2,5 @@ export const fallbackCSS = {
|
|
|
2
2
|
base: "\n body,html {\n font-family: var(--main-font-family, 'sans-serif');\n font-variant: var(--main-font-variant, 'small-caps');\n }\n \n * {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n\n font-family: var(--main-font-family, 'sans-serif');\n font-variant: var(--main-font-variant, 'small-caps');\n }\n\n *::after {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n }\n\n *::before {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n }\n\n hr {\n margin-top: 1rem;\n margin-bottom: 1rem;\n }\n\n h4 {\n font-family: var(--header-font-family, 'sans-serif');\n font-variant: var(--header-font-variant, 'small-caps');\n font-size: 1.2rem;\n text-align: center;\n margin-bottom: 0.2rem;\n margin-top: 0.4rem;\n } \n\n\n h3 {\n font-family: var(--header-font-family, 'sans-serif');\n font-variant: var(--header-font-variant, 'small-caps');\n text-align: center;\n font-size: 1.8rem;\n margin-bottom: 0.6rem;\n margin-top: 1rem;\n } \n\n h2 {\n font-family: var(--header-font-family, 'sans-serif');\n font-variant: var(--header-font-variant, 'small-caps');\n font-size: 2.2rem;\n text-align: center;\n margin-bottom: 0.8rem;\n margin-top: 1.2rem;\n } \n\n\n h1 {\n font-family: var(--header-font-family, 'sans-serif');\n font-variant: var(--header-font-variant, 'small-caps');\n font-size: 3rem;\n text-align: center;\n margin-bottom: 0.8rem;\n margin-top: 1.2rem;\n } \n\n ol {\n padding-left: 0.5rem;\n margin: 1rem;\n }\n\n ul {\n margin-left: 1rem;\n padding-left: 0.2rem;\n }",
|
|
3
3
|
themes: {
|
|
4
4
|
light: '--main-font-color: rgba(34, 49, 63, 1);\n--main-bg-color: rgba(255,255,255,1);\n--main-border-color: rgba(2,48,71,1);\n--main-border: 1px solid var(--main-border-color);\n--accept-font-color: rgba(46, 204, 113, 1);\n--alert-font-color: rgba(157,0,0,1);\n--invalid-border-color: rgba(176,19,19,1);\n--invalid-border: 0.15rem solid var(--invalid-border-color);\n--disable-font-color: rgba(52, 73, 94, 0.4);\n--disabled-border-color: rgba(35,35,35,0.5);\n--disabled-border: 0.1rem solid var(--disabled-border-color);\n--focussed-border-color: rgba(41, 128, 185, 0.9);\n--focussed-border: 0.15rem solid var(--focussed-border-color);\n--focussed-filter: drop-shadow(0 0 0.75rem rgba(41, 128, 185, 0.9));\n--avatar-border: 0.15rem solid rgba(34, 49, 63, 0.9);\n--hamburger-color: rgba(41, 128, 185, 1);\n--hamburger-bg-color: rgba(0,0,0,0);\n--hamburger-filter: drop-shadow(0.2rem 0.2rem 0.2rem rgba(255,255,255,1));\n--gallery-button-bg-color: rgba(220, 235, 245, 0.5);\n--gallery-button-font-color: rgba(15,14,15,0.6);\n--button-font-color: rgba(7,7,7,1);\n--button-bg-color: rgba(52, 152, 219, 1);\n--button-danger-bg-color: rgba(176,19,19,1);\n--button-danger-font-color: rgba(255,255,255,1);\n--button-focus-filter: drop-shadow(0 0 0.75rem rgba(41, 128, 185, 0.9));\n--icon-not-color: rgba(192, 57, 43, 1);\n--icon-disabled-color: rgba(35,35,35,0.4);\n--icon-color: rgba(34, 49, 63, 1);\n--table-odd-bg-color: rgba(236, 240, 241, 1);\n--table-odd-font-color: rgba(0,0,0,1);\n--table-even-bg-color: rgba(220, 225, 229, 1);\n--table-even-font-color: rgba(0,0,0,1);\n--table-header-bg-color: rgba(44, 62, 80, 1);\n--table-header-font-color: rgba(243,243,243,1);\n--table-footer-bg-color: rgba(44, 62, 80, 1);\n--table-footer-font-color: rgba(255, 255, 255, 1);\n--picture-link-bg-color: rgba(52, 73, 94, 0.8);\n--picture-link-font-color: rgba(168,194,250,1);\n--external-link-font-color: rgba(105,152,252,1);\n--attribution-bg-color: rgba(236, 240, 241, 0.6);\n--attribution-font-color: rgba(7,7,7,1);\n--picture-frame-shadow: 0px 1.1px 2.2px rgba(0,0,0,0.02),0px 2.7px 5.3px rgba(0,0,0,0.028),0px 5px 10px rgba(0,0,0,0.035),0px 8.9px 17.9px rgba(0,0,0,0.042),0px 16.7px 33.4px rgba(0,0,0,0.05),0px 40px 80px rgba(0,0,0,0.07);\n--nav-font-color: rgba(255, 255, 255, 1);\n--nav-bg-color: rgba(44, 62, 80, 0.8);\n--title-font-color: rgba(255,255,255,1);\n--title-filter: drop-shadow(0.2rem 0.3rem 0.2rem rgba(0,0,0,1));\n--footer-font-color: rgba(255, 255, 255, 1);\n--footer-bg-color: rgba(44, 62, 80, 1);\n--header-font-color: rgba(255,240,240,1);\n--header-bg-color: rgba(7,7,7,1);\n--acco-card-shadow: -1.2px -3.7px 4.5px rgba(0,0,0,0.017),-1.4px -4.4px 8.9px rgba(0,0,0,0.024),-0.4px -1.3px 13.3px rgba(0,0,0,0.03),1.7px 5.5px 17.9px rgba(0,0,0,0.035),4.9px 15.5px 23.3px rgba(0,0,0,0.04),8.9px 28.2px 30.7px rgba(0,0,0,0.046),13.7px 43.1px 43.8px rgba(0,0,0,0.053),19px 60px 80px rgba(0,0,0,0.07);\n--acco-card-font: rgba(34, 49, 63, 1);\n--acco-card-bg: rgba(255, 255, 255, 1);\n--occuplan-main-border-color: rgba(52, 152, 219, 1);\n--occuplan-main-border: 1px solid var(--occuplan-main-border-color);\n--occuplan-grid-border-color: rgba(52, 152, 219, 0.2);\n--occuplan-grid-border: 0.2px solid var(--occuplan-grid-border-color);\n--occuplan-main-font-color: rgba(52, 152, 219, 1);\n--occuplan-main-bg-color: rgba(255,255,255,0);\n--occuplan-days-font-color: rgba(52, 152, 219, 1);\n--occuplan-days-bg-color: rgba(0,0,0,0);\n--occuplan-days-header-font-color: rgba(255, 255, 255, 1);\n--occuplan-days-header-bg-color: rgba(52, 152, 219, 1);\n--occuplan-weeknum-font-color: rgba(52, 152, 219, 0.5);\n--occuplan-weeknum-bg-color: rgba(0,0,0,0);\n--occuplan-months-font-color: rgba(255, 255, 255, 1);\n--occuplan-months-bg-color: rgba(52, 152, 219, 1);\n--occuplan-invalid-days-font-color: rgba(52, 73, 94, 1);\n--occuplan-invalid-days-bg-color: rgba(149, 165, 166, 0.6);\n--occuplan-weekend-bg-color: rgba(2,48,71,1);\n--occupation-type-1-font-color: rgba(255, 255, 255, 1);\n--occupation-type-1-bg-color: rgba(41, 128, 185, 1);\n--occupation-type-2-font-color: rgba(34, 49, 63, 1);\n--occupation-type-2-bg-colog: rgba(173, 216, 230, 1);\n--occupation-type-3-font-color: rgba(255,255,0,1);\n--occupation-type-3-bg-color: rgba(144, 238, 144, 1);\n--notes-vert-line: 0.5px dashed rgba(2,48,71,0.5);\n--notes-font-color: rgba(44, 62, 80, 1);\n--notes-bg-color: rgba(255, 255, 224, 1);\n--notes-disabled-font-color: rgba(22,0,103,1);\n--notes-disabled-bg-color: rgba(236, 240, 241, 1);\n',
|
|
5
|
-
dark: '--header-font-color: rgba(255,240,240,1);\n--header-bg-color: rgba(7,7,7,1);\n--main-font-color: rgba(255, 255, 255, 1);\n--main-bg-color: rgba(20, 20, 20, 1);\n--main-border-color: rgba(200, 200, 200, 1);\n--main-border: 1px solid var(--main-border-color);\n--accept-font-color: rgba(13, 157, 0, 1);\n--alert-font-color: rgba(255, 0, 0, 1);\n--invalid-border-color: rgba(255, 100, 100, 1);\n--invalid-border: 0.15rem solid var(--invalid-border-color);\n--disable-font-color: rgba(255, 255, 255, 0.4);\n--disabled-border-color: rgba(255, 255, 255, 0.5);\n--disabled-border: 0.1rem solid var(--disabled-border-color);\n--focussed-border-color: rgba(102, 120, 243, 0.9);\n--focussed-border: 0.15rem solid var(--focussed-border-color);\n--focussed-filter: drop-shadow(0 0 0.75rem rgba(102, 120, 243, 0.9));\n--avatar-border: 0.15rem solid rgba(255, 255, 255, 0.9);\n--hamburger-color: rgba(255, 255, 255, 1);\n--hamburger-bg-color: rgba(0, 0, 0, 0);\n--hamburger-filter: drop-shadow(0.2rem 0.2rem 0.2rem rgba(20, 20, 20, 1));\n--gallery-button-bg-color: rgba(30, 30, 30, 0.5);\n--gallery-button-font-color: rgba(255, 255, 255, 0.8);\n--button-font-color: rgba(255, 255, 255, 1);\n--button-bg-color: rgba(30, 30, 30, 1);\n--button-danger-bg-color: rgba(255, 0, 0, 1);\n--button-danger-font-color: rgba(255, 255, 255, 1);\n--button-focus-filter: drop-shadow(0 0 0.75rem rgba(102, 120, 243, 0.9));\n--icon-not-color: rgba(255, 50, 50, 1);\n--icon-disabled-color: rgba(255, 255, 255, 0.4);\n--icon-color: rgba(255, 255, 255, 1);\n--table-odd-bg-color: rgba(40, 40, 40, 1);\n--table-odd-font-color: rgba(255, 255, 255, 1);\n--table-even-bg-color: rgba(50, 50, 50, 1);\n--table-even-font-color: rgba(255, 255, 255, 1);\n--table-header-bg-color: rgba(20, 20, 20, 1);\n--table-header-font-color: rgba(200, 200, 200, 1);\n--table-footer-bg-color: rgba(20, 20, 20, 1);\n--table-footer-font-color: rgba(200, 200, 200, 1);\n--picture-link-bg-color: rgba(100, 100, 100, 0.8);\n--picture-link-font-color: rgba(168, 194, 250, 1);\n--external-link-font-color: rgba(105, 152, 252, 1);\n--attribution-bg-color: rgba(30, 30, 30, 0.9);\n--attribution-font-color: rgba(255, 255, 255, 1);\n--picture-frame-shadow: none;\n--nav-font-color: rgba(255,255,255,1);\n--nav-bg-color: rgba(20, 20, 20, 0.9);\n--title-font-color: rgba(255, 255, 255, 1);\n--title-filter: drop-shadow(0.2rem 0.3rem 0.2rem rgba(0,0,0,1)));\n--footer-font-color: rgba(225,233,254,1);\n--footer-bg-color: rgba(20, 20, 20, 1);\n--footer-font-color: rgba(225,233,254,1);\n--footer-bg-color: rgba(20, 20, 20, 1);\n--acco-card-shadow: none;\n--acco-card-font: rgba(255,229,229,1);\n--acco-card-bg: rgba(30, 30, 30, 1);\n--occuplan-main-border-color: rgba(200, 200, 200, 1);\n--occuplan-main-border: 1px solid var(--occuplan-main-border-color);\n--occuplan-grid-border-color: rgba(200, 200, 200, 0.2);\n--occuplan-grid-border: 0.2px solid var(--occuplan-grid-border-color);\n--occuplan-main-font-color: rgba(200, 200, 200, 1);\n--occuplan-main-bg-color: rgba(30, 30, 30, 0);\n--occuplan-days-font-color: rgba(200, 200, 200, 1);\n--occuplan-days-bg-color: rgba(0, 0, 0, 0);\n--occuplan-days-header-font-color: rgba(200, 200, 200, 1);\n--occuplan-days-header-bg-color: rgba(50, 50, 50, 1);\n--occuplan-weeknum-font-color: rgba(200, 200, 200, 0.5);\n--occuplan-weeknum-bg-color: rgba(0, 0, 0, 0);\n--occuplan-months-font-color: rgba(200, 200, 200, 1);\n--occuplan-months-bg-color: rgba(50, 50, 50, 1);\n--occuplan-invalid-days-font-color: rgba(255, 255, 255, 1);\n--occuplan-invalid-days-bg-color: rgba(110, 110, 110, 0.8);\n--occuplan-weekend-bg-color: rgba(200, 200, 200, 1);\n--occupation-type-1-font-color: rgba(200, 200, 200, 1);\n--occupation-type-1-bg-color: rgba(33, 158, 188, 1);\n--occupation-type-2-font-color: rgba(255, 255, 255, 1);\n--occupation-type-2-bg-colog: rgba(249,112,249,1);\n--occupation-type-3-font-color: rgba(255, 255, 255, 1);\n--occupation-type-3-bg-color: rgba(0, 112, 23, 1);\n--notes-vert-line: 0.5px dashed rgba(200, 200, 200, 0.5);\n--notes-font-color: rgba(255, 255, 255, 1);\n--notes-bg-color: rgba(50, 50, 50, 1);\n--notes-disabled-font-color: rgba(255, 255, 255, 1);\n--notes-disabled-bg-color: rgba(70, 70, 70, 1);\n',
|
|
6
5
|
},
|
|
7
6
|
};
|
package/dist/types.d.ts
CHANGED
|
@@ -348,7 +348,6 @@ export interface Style {
|
|
|
348
348
|
base: string;
|
|
349
349
|
themes: {
|
|
350
350
|
light: string;
|
|
351
|
-
dark: string;
|
|
352
351
|
};
|
|
353
352
|
}
|
|
354
353
|
export interface PageConfig {
|
|
@@ -373,7 +372,6 @@ export interface PageProps {
|
|
|
373
372
|
fixedHamburger?: boolean;
|
|
374
373
|
navbarOverHamburger?: boolean;
|
|
375
374
|
disableLinks?: boolean;
|
|
376
|
-
selectedTheme?: 'light' | 'dark';
|
|
377
375
|
content?: Section[];
|
|
378
376
|
}
|
|
379
377
|
export interface NavItem {
|