svelte-common 4.6.4 → 4.6.7

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/README.md CHANGED
@@ -1,7 +1,7 @@
1
1
  [![Svelte v3](https://img.shields.io/badge/svelte-v3-orange.svg)](https://svelte.dev)
2
2
  [![npm](https://img.shields.io/npm/v/svelte-common.svg)](https://www.npmjs.com/package/svelte-common)
3
3
  [![License](https://img.shields.io/badge/License-BSD%203--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause)
4
- [![minified size](https://badgen.net/bundlephobia/min/svelte-common)](https://bundlephobia.com/result?p=svelte-common)
4
+ [![Open Bundle](https://bundlejs.com/badge-light.svg)](https://bundlejs.com/?q=svelte-common)
5
5
  [![downloads](http://img.shields.io/npm/dm/svelte-common.svg?style=flat-square)](https://npmjs.org/package/svelte-common)
6
6
  [![GitHub Issues](https://img.shields.io/github/issues/arlac77/svelte-common.svg?style=flat-square)](https://github.com/arlac77/svelte-common/issues)
7
7
  [![Build Status](https://img.shields.io/endpoint.svg?url=https%3A%2F%2Factions-badge.atrox.dev%2Farlac77%2Fsvelte-common%2Fbadge\&style=flat)](https://actions-badge.atrox.dev/arlac77/svelte-common/goto)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "svelte-common",
3
- "version": "4.6.4",
3
+ "version": "4.6.7",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -26,14 +26,14 @@
26
26
  "test:cafe": "testcafe $BROWSER:headless tests/cafe/*.js -s build/test --page-request-timeout 9000 --app-init-delay 3000 --app vite",
27
27
  "test:ava": "ava --timeout 2m tests/*.mjs",
28
28
  "docs": "documentation readme --section=API ./src/**/*.mjs",
29
- "lint": "npm run lint:css && npm run lint:docs && documentation lint ./src/index.mjs",
29
+ "lint": "npm run lint:css && npm run lint:docs",
30
30
  "lint:docs": "documentation lint ./src/**/*.mjs",
31
31
  "lint:css": "stylelint ./src/*.css",
32
32
  "preview": "vite preview"
33
33
  },
34
34
  "dependencies": {
35
- "svelte-command": "^1.1.18",
36
- "svelte-entitlement": "^1.2.25"
35
+ "svelte-command": "^1.1.20",
36
+ "svelte-entitlement": "^1.2.26"
37
37
  },
38
38
  "devDependencies": {
39
39
  "@semantic-release/commit-analyzer": "^9.0.2",
@@ -42,8 +42,8 @@
42
42
  "@sveltejs/vite-plugin-svelte": "^1.0.1",
43
43
  "ava": "^4.3.1",
44
44
  "documentation": "^13.2.5",
45
- "mf-styling": "^1.2.26",
46
- "npm-pkgbuild": "^10.11.2",
45
+ "mf-styling": "^1.2.31",
46
+ "npm-pkgbuild": "^10.11.3",
47
47
  "semantic-release": "^19.0.3",
48
48
  "stylelint": "^14.9.1",
49
49
  "stylelint-config-standard": "^26.0.0",
@@ -52,7 +52,7 @@
52
52
  "vite": "^3.0.0"
53
53
  },
54
54
  "optionalDependencies": {
55
- "mf-hosting": "^1.7.0"
55
+ "mf-hosting": "^1.7.1"
56
56
  },
57
57
  "repository": {
58
58
  "type": "git",
@@ -67,8 +67,7 @@
67
67
  "${install.dir}": "build/",
68
68
  "${nginx.sites.dir}${name}.conf": "pkg/nginx.conf"
69
69
  },
70
- "groups": "examples",
71
- "http.base.path": "/examples"
70
+ "groups": "examples"
72
71
  },
73
72
  "release": {
74
73
  "plugins": [
@@ -4,17 +4,6 @@
4
4
 
5
5
  export let server;
6
6
 
7
- if (!server) {
8
- server = {};
9
- }
10
- const memory = server.memory || {
11
- heapTotal: 0,
12
- heapUsed: 0,
13
- external: 0,
14
- rss: 0,
15
- arrayBuffers: 0
16
- };
17
-
18
7
  const memSlots = [
19
8
  { key: "external", title: "External" },
20
9
  { key: "heapTotal", title: "Heap Total" },
@@ -30,22 +19,21 @@
30
19
  <tr>
31
20
  <td />
32
21
  <td>Version</td>
33
- <td>{server.version}</td>
22
+ <td>{#if server && server.version}{server.version}{:else}<div class="error">down</div>{/if}</td>
34
23
  </tr>
35
24
  <tr>
36
25
  <td />
37
26
  <td>Uptime</td>
38
27
  <td>
39
- {#if server.uptime >= 0}
28
+ {#if server && server.uptime >= 0}
40
29
  <Duration seconds={server.uptime} />
41
30
  {:else}<div class="error">down</div>{/if}
42
31
  </td>
43
32
  </tr>
44
-
45
33
  {#each memSlots as { key, title }}
46
34
  <tr>
47
35
  <td />
48
36
  <td>{title}</td>
49
- <td><Bytes value={memory[key]} /></td>
37
+ <td>{#if server && server.memory}<Bytes value={server.memory[key]}/>{:else}<div class="error">down</div>{/if}</td>
50
38
  </tr>
51
39
  {/each}