@movvjs/svelte-schedule-view 0.2.7-beta-1 → 0.2.8-beta-1

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 @@ import { env } from "../store/env";
6
6
  import { Alert, Confirm } from "./components/notifications";
7
7
  import Loader from "./components/loader/Loader.svelte";
8
8
  import { onMount } from "svelte";
9
+ export let googleMapsApiKey;
9
10
  init({
10
11
  fallbackLocale: "en",
11
12
  initialLocale: "en"
@@ -35,7 +36,7 @@ onMount(() => {
35
36
  }));
36
37
  d[l] ? console.warn(p + " only loads once. Ignoring:", g) : d[l] = (f, ...n) => r.add(f) && u().then(() => d[l](f, ...n));
37
38
  })({
38
- key: "AIzaSyAYfGXhjCqlD5FlfmdtzkMSD7XONh0HS6s",
39
+ key: googleMapsApiKey,
39
40
  v: "weekly",
40
41
  region: "kr",
41
42
  language: navigator?.language || "en"
@@ -1,7 +1,9 @@
1
1
  import { SvelteComponent } from "svelte";
2
2
  import './assets/scss/indie_booking.scss';
3
3
  declare const __propDef: {
4
- props: Record<string, never>;
4
+ props: {
5
+ googleMapsApiKey: string;
6
+ };
5
7
  events: {
6
8
  [evt: string]: CustomEvent<any>;
7
9
  };
@@ -30,6 +30,7 @@ const {
30
30
  fullName,
31
31
  selectedPrice
32
32
  } = copiedBooking;
33
+ export let googleMapsApiKey;
33
34
  let on = false;
34
35
  let resolver;
35
36
  $:
@@ -160,7 +161,7 @@ async function save() {
160
161
  </script>
161
162
 
162
163
  <Toaster />
163
- <Layout>
164
+ <Layout {googleMapsApiKey}>
164
165
  <section class="indie_pop_wrap scroll" class:on>
165
166
  {#if on}
166
167
  <div class="pop_base full_2 indie_passengers_info_pop">
@@ -13,6 +13,7 @@ export interface InitOption {
13
13
  import type { Locale, Target } from './types';
14
14
  declare const __propDef: {
15
15
  props: {
16
+ googleMapsApiKey: string;
16
17
  init?: (options: InitOption) => {
17
18
  open: ({ code }: {
18
19
  code: string;
@@ -82,7 +82,6 @@ declare module '$env/static/private' {
82
82
  export const npm_config_argv: string;
83
83
  export const npm_package_devDependencies__types_qs: string;
84
84
  export const _: string;
85
- export const LaunchInstanceID: string;
86
85
  export const npm_package_dependencies_svelte_i18n: string;
87
86
  export const npm_package_dependencies_svelte_french_toast: string;
88
87
  export const npm_config_engine_strict: string;
@@ -159,7 +158,6 @@ declare module '$env/static/private' {
159
158
  export const npm_package_files_0: string;
160
159
  export const npm_config_init_version: string;
161
160
  export const npm_config_ignore_optional: string;
162
- export const SECURITYSESSIONID: string;
163
161
  export const npm_package_dependencies_svelte_portal: string;
164
162
  export const npm_package_scripts_check: string;
165
163
  export const COLORTERM: string;
@@ -253,7 +251,6 @@ declare module '$env/dynamic/private' {
253
251
  npm_config_argv: string;
254
252
  npm_package_devDependencies__types_qs: string;
255
253
  _: string;
256
- LaunchInstanceID: string;
257
254
  npm_package_dependencies_svelte_i18n: string;
258
255
  npm_package_dependencies_svelte_french_toast: string;
259
256
  npm_config_engine_strict: string;
@@ -330,7 +327,6 @@ declare module '$env/dynamic/private' {
330
327
  npm_package_files_0: string;
331
328
  npm_config_init_version: string;
332
329
  npm_config_ignore_optional: string;
333
- SECURITYSESSIONID: string;
334
330
  npm_package_dependencies_svelte_portal: string;
335
331
  npm_package_scripts_check: string;
336
332
  COLORTERM: string;
@@ -21,7 +21,7 @@ export const options = {
21
21
  app: ({ head, body, assets, nonce, env }) => "<!DOCTYPE html>\n<html lang=\"en\">\n\t<head>\n\t\t<meta charset=\"utf-8\" />\n\t\t<link rel=\"icon\" href=\"" + assets + "/favicon.png\" />\n\t\t<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\" />\n\t\t<meta name=\"referrer\" content=\"no-referrer\" />\n\t\t" + head + "\n\t</head>\n\t<body data-sveltekit-preload-data=\"hover\">\n\t\t<div>" + body + "</div>\n\t</body>\n</html>\n",
22
22
  error: ({ status, message }) => "<!doctype html>\n<html lang=\"en\">\n\t<head>\n\t\t<meta charset=\"utf-8\" />\n\t\t<title>" + message + "</title>\n\n\t\t<style>\n\t\t\tbody {\n\t\t\t\t--bg: white;\n\t\t\t\t--fg: #222;\n\t\t\t\t--divider: #ccc;\n\t\t\t\tbackground: var(--bg);\n\t\t\t\tcolor: var(--fg);\n\t\t\t\tfont-family:\n\t\t\t\t\tsystem-ui,\n\t\t\t\t\t-apple-system,\n\t\t\t\t\tBlinkMacSystemFont,\n\t\t\t\t\t'Segoe UI',\n\t\t\t\t\tRoboto,\n\t\t\t\t\tOxygen,\n\t\t\t\t\tUbuntu,\n\t\t\t\t\tCantarell,\n\t\t\t\t\t'Open Sans',\n\t\t\t\t\t'Helvetica Neue',\n\t\t\t\t\tsans-serif;\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t\tjustify-content: center;\n\t\t\t\theight: 100vh;\n\t\t\t\tmargin: 0;\n\t\t\t}\n\n\t\t\t.error {\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t\tmax-width: 32rem;\n\t\t\t\tmargin: 0 1rem;\n\t\t\t}\n\n\t\t\t.status {\n\t\t\t\tfont-weight: 200;\n\t\t\t\tfont-size: 3rem;\n\t\t\t\tline-height: 1;\n\t\t\t\tposition: relative;\n\t\t\t\ttop: -0.05rem;\n\t\t\t}\n\n\t\t\t.message {\n\t\t\t\tborder-left: 1px solid var(--divider);\n\t\t\t\tpadding: 0 0 0 1rem;\n\t\t\t\tmargin: 0 0 0 1rem;\n\t\t\t\tmin-height: 2.5rem;\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t}\n\n\t\t\t.message h1 {\n\t\t\t\tfont-weight: 400;\n\t\t\t\tfont-size: 1em;\n\t\t\t\tmargin: 0;\n\t\t\t}\n\n\t\t\t@media (prefers-color-scheme: dark) {\n\t\t\t\tbody {\n\t\t\t\t\t--bg: #222;\n\t\t\t\t\t--fg: #ddd;\n\t\t\t\t\t--divider: #666;\n\t\t\t\t}\n\t\t\t}\n\t\t</style>\n\t</head>\n\t<body>\n\t\t<div class=\"error\">\n\t\t\t<span class=\"status\">" + status + "</span>\n\t\t\t<div class=\"message\">\n\t\t\t\t<h1>" + message + "</h1>\n\t\t\t</div>\n\t\t</div>\n\t</body>\n</html>\n"
23
23
  },
24
- version_hash: "akhry5"
24
+ version_hash: "42f2c3"
25
25
  };
26
26
 
27
27
  export async function get_hooks() {
@@ -6,6 +6,7 @@ import { env } from "../store/env";
6
6
  import { Alert, Confirm } from "./components/notifications";
7
7
  import Loader from "./components/loader/Loader.svelte";
8
8
  import { onMount } from "svelte";
9
+ export let googleMapsApiKey;
9
10
  init({
10
11
  fallbackLocale: "en",
11
12
  initialLocale: "en"
@@ -35,7 +36,7 @@ onMount(() => {
35
36
  }));
36
37
  d[l] ? console.warn(p + " only loads once. Ignoring:", g) : d[l] = (f, ...n) => r.add(f) && u().then(() => d[l](f, ...n));
37
38
  })({
38
- key: "AIzaSyAYfGXhjCqlD5FlfmdtzkMSD7XONh0HS6s",
39
+ key: googleMapsApiKey,
39
40
  v: "weekly",
40
41
  region: "kr",
41
42
  language: navigator?.language || "en"
@@ -1,7 +1,9 @@
1
1
  import { SvelteComponent } from "svelte";
2
2
  import './assets/scss/indie_booking.scss';
3
3
  declare const __propDef: {
4
- props: Record<string, never>;
4
+ props: {
5
+ googleMapsApiKey: string;
6
+ };
5
7
  events: {
6
8
  [evt: string]: CustomEvent<any>;
7
9
  };
@@ -30,6 +30,7 @@ const {
30
30
  fullName,
31
31
  selectedPrice
32
32
  } = copiedBooking;
33
+ export let googleMapsApiKey;
33
34
  let on = false;
34
35
  let resolver;
35
36
  $:
@@ -160,7 +161,7 @@ async function save() {
160
161
  </script>
161
162
 
162
163
  <Toaster />
163
- <Layout>
164
+ <Layout {googleMapsApiKey}>
164
165
  <section class="indie_pop_wrap scroll" class:on>
165
166
  {#if on}
166
167
  <div class="pop_base full_2 indie_passengers_info_pop">
@@ -13,6 +13,7 @@ export interface InitOption {
13
13
  import type { Locale, Target } from './types';
14
14
  declare const __propDef: {
15
15
  props: {
16
+ googleMapsApiKey: string;
16
17
  init?: (options: InitOption) => {
17
18
  open: ({ code }: {
18
19
  code: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@movvjs/svelte-schedule-view",
3
- "version": "0.2.7-beta-1",
3
+ "version": "0.2.8-beta-1",
4
4
  "type": "module",
5
5
  "license": "ISC",
6
6
  "author": {
@@ -12,6 +12,8 @@
12
12
  import Loader from './components/loader/Loader.svelte'
13
13
  import { onMount } from 'svelte'
14
14
 
15
+ export let googleMapsApiKey: string
16
+
15
17
  init({
16
18
  fallbackLocale: 'en',
17
19
  initialLocale: 'en'
@@ -29,7 +31,7 @@
29
31
  // https://developers.google.com/maps/documentation/javascript/load-maps-js-api?hl=ko#dynamic-library-import
30
32
  // prettier-ignore
31
33
  ;(g=>{var h,a,k,p="The Google Maps JavaScript API",c="google",l="importLibrary",q="__ib__",m=document,b=window;b=b[c]||(b[c]={});var d=b.maps||(b.maps={}),r=new Set,e=new URLSearchParams,u=()=>h||(h=new Promise(async(f,n)=>{await (a=m.createElement("script"));e.set("libraries",[...r]+"");for(k in g)e.set(k.replace(/[A-Z]/g,t=>"_"+t[0].toLowerCase()),g[k]);e.set("callback",c+".maps."+q);a.src=`https://maps.${c}apis.com/maps/api/js?`+e;d[q]=f;a.onerror=()=>h=n(Error(p+" could not load."));a.nonce=m.querySelector("script[nonce]")?.nonce||"";m.head.append(a)}));d[l]?console.warn(p+" only loads once. Ignoring:",g):d[l]=(f,...n)=>r.add(f)&&u().then(()=>d[l](f,...n))})({
32
- key: "AIzaSyAYfGXhjCqlD5FlfmdtzkMSD7XONh0HS6s",
34
+ key: googleMapsApiKey,
33
35
  v: "weekly",
34
36
  region: "kr",
35
37
  language: navigator?.language || "en",
@@ -49,6 +49,8 @@
49
49
  selectedPrice
50
50
  } = copiedBooking
51
51
 
52
+ export let googleMapsApiKey: string
53
+
52
54
  let on = false
53
55
  let resolver: (value: Awaited<ReturnType<typeof open>>) => void
54
56
 
@@ -214,7 +216,7 @@
214
216
  </script>
215
217
 
216
218
  <Toaster />
217
- <Layout>
219
+ <Layout {googleMapsApiKey}>
218
220
  <section class="indie_pop_wrap scroll" class:on>
219
221
  {#if on}
220
222
  <div class="pop_base full_2 indie_passengers_info_pop">
@@ -96,7 +96,7 @@
96
96
  </script>
97
97
 
98
98
  <Toaster />
99
- <Schedule bind:this={schedule$} />
99
+ <Schedule bind:this={schedule$} googleMapsApiKey="AIzaSyAYfGXhjCqlD5FlfmdtzkMSD7XONh0HS6s" />
100
100
 
101
101
  <section>
102
102
  <div>