@everymatrix/general-player-login-form 0.0.189 → 0.0.193
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,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@everymatrix/general-player-login-form",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.193",
|
|
4
4
|
"main": "dist/general-player-login-form.js",
|
|
5
5
|
"svelte": "src/index.ts",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"start": "sirv public",
|
|
8
|
-
"build": "cross-env NODE_ENV
|
|
8
|
+
"build": "cross-env NODE_ENV=production rollup -c",
|
|
9
9
|
"dev": "cross-env NODE_ENV=\"development\" rollup -c -w",
|
|
10
10
|
"validate": "svelte-check",
|
|
11
11
|
"test": "echo"
|
|
@@ -36,5 +36,5 @@
|
|
|
36
36
|
"publishConfig": {
|
|
37
37
|
"access": "public"
|
|
38
38
|
},
|
|
39
|
-
"gitHead": "
|
|
39
|
+
"gitHead": "0960983a499b8cd9494500f0f36058fdc61fbead"
|
|
40
40
|
}
|
package/rollup.config.js
CHANGED
|
@@ -6,8 +6,11 @@ import livereload from 'rollup-plugin-livereload';
|
|
|
6
6
|
import { terser } from 'rollup-plugin-terser';
|
|
7
7
|
import sveltePreprocess from 'svelte-preprocess';
|
|
8
8
|
import typescript from '@rollup/plugin-typescript';
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
import uglify from 'rollup-plugin-uglify';
|
|
10
|
+
import image from '@rollup/plugin-image';
|
|
11
|
+
|
|
12
|
+
const production = process.env.NODE_ENV == 'production';
|
|
13
|
+
const dev = process.env.NODE_ENV == 'development';
|
|
11
14
|
|
|
12
15
|
export default {
|
|
13
16
|
input: 'src/index.ts',
|
|
@@ -15,17 +18,21 @@ export default {
|
|
|
15
18
|
sourcemap: true,
|
|
16
19
|
format: 'umd',
|
|
17
20
|
name: 'app',
|
|
18
|
-
file: 'dist/general-player-login-form.js'
|
|
21
|
+
file: 'dist/general-player-login-form.js',
|
|
19
22
|
},
|
|
20
23
|
plugins: [
|
|
21
24
|
svelte({
|
|
22
25
|
preprocess: sveltePreprocess(),
|
|
23
26
|
compilerOptions: {
|
|
27
|
+
// @TODO check generate and hydratable
|
|
28
|
+
// generate: 'ssr',
|
|
29
|
+
// hydratable: true,
|
|
24
30
|
// enable run-time checks when not in production
|
|
25
31
|
customElement: true,
|
|
26
32
|
dev: !production
|
|
27
33
|
}
|
|
28
34
|
}),
|
|
35
|
+
image(),
|
|
29
36
|
commonjs(),
|
|
30
37
|
resolve({
|
|
31
38
|
browser: true,
|
|
@@ -46,12 +53,13 @@ export default {
|
|
|
46
53
|
}),
|
|
47
54
|
// If we're building for production (npm run build
|
|
48
55
|
// instead of npm run dev), minify
|
|
49
|
-
production &&
|
|
56
|
+
production &&
|
|
50
57
|
terser({
|
|
51
58
|
output: {
|
|
52
59
|
comments: "all"
|
|
53
60
|
},
|
|
54
|
-
})
|
|
61
|
+
}),
|
|
62
|
+
production && uglify.uglify()
|
|
55
63
|
],
|
|
56
64
|
watch: {
|
|
57
65
|
clearScreen: false
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
|
|
29
29
|
const regexValidators = {
|
|
30
30
|
user: /^(?!(?:.*\d){9})(?=(?:.*[a-zA-Z]){2})^[a-zA-Z\d]*$/,
|
|
31
|
-
email: /^[
|
|
31
|
+
email: /^(([^<>()[\]\.,;:\s@\"]+(\.[^<>()[\]\.,;:\s@\"]+)*)|(\".+\"))@(([^<>()[\]\.,;:\s@\"]+\.)+[^<>()[\]\.,;:\s@\"]{2,})$/i,
|
|
32
32
|
password: /^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[0-9])(?=.*?[^\w\s]).{8,20}$/
|
|
33
33
|
}
|
|
34
34
|
|
|
@@ -160,14 +160,14 @@
|
|
|
160
160
|
<div class="FormContent">
|
|
161
161
|
<div class="UserContainer {invalidName ? 'InvalidField' : ''}">
|
|
162
162
|
<label for="UserName">Username or Email:<span class="FormRequired">*</span></label>
|
|
163
|
-
<input bind:value={userValue} on:
|
|
163
|
+
<input bind:value={userValue} on:keyup={validateUserName} type="text" id="UserName" />
|
|
164
164
|
{#if invalidName}
|
|
165
165
|
<p class="InvalidInput">Name must be at least 2 characters long, and contain no special characters. Email should contain '@' and a 2-3 letter long domain.</p>
|
|
166
166
|
{/if}
|
|
167
167
|
</div>
|
|
168
168
|
<div class="PasswordContainer {invalidPassword ? 'InvalidField' : ''}">
|
|
169
169
|
<label for="Password">Password:<span class="FormRequired">*</span></label>
|
|
170
|
-
<input bind:value={userPassword} on:
|
|
170
|
+
<input bind:value={userPassword} on:keyup={validatePassword} type="password" id="Password" bind:this={passwordVisibilityToggle} />
|
|
171
171
|
{#if isPasswordVisible}
|
|
172
172
|
<svg on:click={() => hidePassword()} class="TogglePasswordVisibility" xmlns="http://www.w3.org/2000/svg" width="18.844" height="12.887" viewBox="0 0 18.844 12.887"><defs><style>.a{fill:#07072a;}</style></defs><g transform="translate(-110.856 -23.242)"><circle class="a" cx="0.05" cy="0.05" r="0.05" transform="translate(121.017 31.148)"/><g transform="translate(117.499 27.37)"><path class="a" d="M147.413,43.174a2.774,2.774,0,0,0-3.229-3.943Z" transform="translate(-142.164 -39.123)"/><path class="a" d="M137.031,43.1a2.778,2.778,0,0,0,3.447,4.209Z" transform="translate(-136.413 -42.068)"/></g><g transform="translate(110.856 24.899)"><path class="a" d="M122.538,42.061a7.043,7.043,0,0,1-2.325.53,10.373,10.373,0,0,1-4.393-1.482,36.509,36.509,0,0,1-3.873-2.391.13.13,0,0,1,0-.208,44.141,44.141,0,0,1,3.873-2.651c.394-.233.768-.437,1.13-.622l-.686-.838c-.322.167-.651.347-.99.55a37.989,37.989,0,0,0-3.977,2.729,1.21,1.21,0,0,0-.442.962,1.1,1.1,0,0,0,.494.936,34.416,34.416,0,0,0,3.977,2.469,11.468,11.468,0,0,0,4.886,1.611,8.427,8.427,0,0,0,3.039-.725Z" transform="translate(-110.856 -33.157)"/><path class="a" d="M149.119,34.14a45.875,45.875,0,0,0-4.055-2.729,20.541,20.541,0,0,0-2.547-1.248,5.6,5.6,0,0,0-4.79-.017l.7.856a5.254,5.254,0,0,1,1.672-.346,10.072,10.072,0,0,1,4.445,1.663,34.132,34.132,0,0,1,3.925,2.651.13.13,0,0,1,0,.208,40.2,40.2,0,0,1-3.925,2.391c-.179.092-.352.176-.525.26l.684.835c.1-.054.2-.1.309-.159a36.356,36.356,0,0,0,4.055-2.469,1.067,1.067,0,0,0,.52-.936A1.159,1.159,0,0,0,149.119,34.14Z" transform="translate(-130.743 -29.617)"/></g><rect class="a" width="0.972" height="15.861" rx="0.486" transform="translate(114.827 23.858) rotate(-39.315)"/></g></svg>
|
|
173
173
|
{:else}
|