pwa-auth 1.2.1 → 1.2.3
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/CHANGELOG.md +6 -0
- package/README.md +41 -17
- package/demo/index.html +16 -5
- package/demo/styles.css +5 -0
- package/deploy/custom-elements/drawer/css/drawer.d.ts.map +1 -1
- package/deploy/custom-elements/drawer/css/drawer.js +11 -0
- package/deploy/custom-elements/drawer/css/old/visibility.d.ts +3 -0
- package/deploy/custom-elements/drawer/css/old/visibility.d.ts.map +1 -0
- package/deploy/custom-elements/drawer/css/old/visibility.js +22 -0
- package/deploy/custom-elements/drawer/css/paragraph.d.ts.map +1 -1
- package/deploy/custom-elements/drawer/css/paragraph.js +4 -5
- package/deploy/custom-elements/drawer/css/visibility.d.ts.map +1 -1
- package/deploy/custom-elements/drawer/css/visibility.js +4 -2
- package/deploy/custom-elements/drawer/drawer.d.ts.map +1 -1
- package/deploy/custom-elements/drawer/drawer.js +19 -13
- package/npm/pwa-auth.js +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -14,6 +14,12 @@ Security - in case of vulnerabilities.
|
|
|
14
14
|
|
|
15
15
|
# [1.1.6] - 2025-08-25
|
|
16
16
|
|
|
17
|
+
## Changed
|
|
18
|
+
- Login Button Standard Height: Medium: 40px
|
|
19
|
+
- Drawer Animation: from 3d transition, to max-height mechanism
|
|
20
|
+
|
|
21
|
+
# [1.1.6] - 2025-08-25
|
|
22
|
+
|
|
17
23
|
## Changed
|
|
18
24
|
- Drawer - should be the custome element itself, not internal wrapper
|
|
19
25
|
|
package/README.md
CHANGED
|
@@ -1,10 +1,26 @@
|
|
|
1
|
-
Progressive Website Application Authentication
|
|
1
|
+
Progressive Website Application - Authentication
|
|
2
2
|
======================
|
|
3
3
|
|
|
4
|
-
#
|
|
5
|
-
|
|
4
|
+
# PWA-Auth Components [Demo](https://pwa-authentic.firebaseapp.com)
|
|
5
|
+
Hello, and welcome to Jack's Publishing of Custom HTML Elements.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
PWA-AUTH is a bundle of 3 Custom HTML Elements for Firebase (IAM) Authenication using email and password, with the ability to change username, icon, email, password, or delete your own account and it's content all together.
|
|
8
|
+
|
|
9
|
+
You will learn how to reference, initialize, and place 3 Custom HTML Tags for use. By either <b>Standard</b> or <b>Modular</b> ECMA Script.
|
|
10
|
+
|
|
11
|
+
Authentication Components are for anyone who is looking for a quick and simple way to sign-up, log-in, log-out, modify, or delete a firebase account from thier own personal domain.
|
|
12
|
+
|
|
13
|
+
Jack's Publishing is dedicated to maintaining components for your projects. This specific project is design to be simple, and meet basic user needs, with the interplay of an Icon Button, Drop-down Drawer, and a Settings Page.
|
|
14
|
+
|
|
15
|
+
Continue reading to start installing the bundle:
|
|
16
|
+
- Pick the JavaScript File Type to Reference
|
|
17
|
+
- Understand the Library Features
|
|
18
|
+
- Understand the Library Boilerplate
|
|
19
|
+
- 3 Tag Placement
|
|
20
|
+
- Color Scheme: CSS Custom Properties
|
|
21
|
+
- Firebase Initialization
|
|
22
|
+
|
|
23
|
+
## Standard, Namespaced JavaScript
|
|
8
24
|
- copy the bundle: node_modules/pwa-auth/npm/pwa-auth.js
|
|
9
25
|
|
|
10
26
|
## Module JavaScript
|
|
@@ -18,15 +34,7 @@ import 'pwa-auth';
|
|
|
18
34
|
- Predicate State Behavior: [Redux](https://redux.js.org/)
|
|
19
35
|
- Frontend: [Lit](https://lit.dev)
|
|
20
36
|
|
|
21
|
-
##
|
|
22
|
-
- 3 Tag Placements (Custom HTML Elements)
|
|
23
|
-
- user-icon
|
|
24
|
-
- user-drawer
|
|
25
|
-
- user-settings
|
|
26
|
-
- Cascading Style Sheets (CSS)
|
|
27
|
-
- ECMA Script (JavaScript)
|
|
28
|
-
|
|
29
|
-
## Features:
|
|
37
|
+
## PWA-AUTH Features:
|
|
30
38
|
- Register through Email and Password
|
|
31
39
|
- Log-in
|
|
32
40
|
- Log-out
|
|
@@ -36,6 +44,14 @@ import 'pwa-auth';
|
|
|
36
44
|
- Change Password
|
|
37
45
|
- Delete Account
|
|
38
46
|
|
|
47
|
+
## Boilerplate
|
|
48
|
+
- 3 Tag Placements (Custom HTML Elements)
|
|
49
|
+
- user-icon
|
|
50
|
+
- user-drawer
|
|
51
|
+
- user-settings
|
|
52
|
+
- Cascading Style Sheets (CSS)
|
|
53
|
+
- ECMA Script (JavaScript)
|
|
54
|
+
|
|
39
55
|
## Custom Elements
|
|
40
56
|
|
|
41
57
|
### `<user-icon>`
|
|
@@ -151,10 +167,11 @@ import 'pwa-auth';
|
|
|
151
167
|
- Firebase Project
|
|
152
168
|
|
|
153
169
|
## Firebase Setup
|
|
154
|
-
- Authentication - email
|
|
155
|
-
- Cloud
|
|
156
|
-
- Cloud Storage
|
|
170
|
+
- Authentication - email login
|
|
171
|
+
- Cloud Storage - icon save location
|
|
157
172
|
|
|
173
|
+
## Firebase Instance Configuration
|
|
174
|
+
### Modular Firebase Initialization
|
|
158
175
|
```javascript
|
|
159
176
|
// Initialize Firebase
|
|
160
177
|
let connect = {
|
|
@@ -171,8 +188,15 @@ let connect = {
|
|
|
171
188
|
if (lolalhost) { connect = { /* etc. */ } }
|
|
172
189
|
```
|
|
173
190
|
|
|
191
|
+
### Global Namespaced Firebase Configuration
|
|
192
|
+
pwa-auth is built upon the Firebase SDK (Software Development Kit).
|
|
193
|
+
The entire bundle is one instance of firebase that takes in the configuration information, internally.
|
|
194
|
+
|
|
195
|
+
If you are looking for a Namespaced Firebase Configuration, please send it as feedback, and will make that version for you.
|
|
196
|
+
|
|
174
197
|
# Feedback
|
|
175
198
|
All feedback, comments, bugs, and requests are welcome.
|
|
176
199
|
* [Jack's Publishing](https://www.jackspublishing.com)
|
|
177
200
|
* [contractor's centre](https://www.contractorscentre.com)
|
|
178
|
-
* [Node Package Manager](https://www.npmjs.com/package/pwa-auth)
|
|
201
|
+
* [Node Package Manager](https://www.npmjs.com/package/pwa-auth)
|
|
202
|
+
* [Sponsor Jacek Markiewicz](https://github.com/sponsors/busynest/button)
|
package/demo/index.html
CHANGED
|
@@ -41,14 +41,25 @@
|
|
|
41
41
|
<!-- Start Body -->
|
|
42
42
|
<body>
|
|
43
43
|
|
|
44
|
-
|
|
45
|
-
<header><user-icon register></user-icon></header>
|
|
44
|
+
<header>
|
|
46
45
|
|
|
47
|
-
|
|
46
|
+
<!-- Sponsor Me -->
|
|
47
|
+
<iframe src="https://github.com/sponsors/busynest/button" title="Sponsor busynest" height="32" width="114" style="border: 0; border-radius: 6px; margin: auto 0 auto 0;"></iframe>
|
|
48
|
+
|
|
49
|
+
<!-- Icon Tag -->
|
|
50
|
+
<user-icon register></user-icon>
|
|
51
|
+
|
|
52
|
+
</header>
|
|
53
|
+
|
|
54
|
+
<!-- Drawer Tag-->
|
|
48
55
|
<user-drawer register url="/demo/settings"></user-drawer>
|
|
49
56
|
|
|
50
|
-
|
|
51
|
-
|
|
57
|
+
<main>
|
|
58
|
+
|
|
59
|
+
<!-- Settings Tag-->
|
|
60
|
+
<user-settings></user-settings>
|
|
61
|
+
|
|
62
|
+
</main>
|
|
52
63
|
|
|
53
64
|
<!-- CSS: Custom Variables: <head> tag -->
|
|
54
65
|
<style>
|
package/demo/styles.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"drawer.d.ts","sourceRoot":"","sources":["../../../../src/custom-elements/drawer/css/drawer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAC;AAErC,eAAO,MAAM,WAAW,EAAE,
|
|
1
|
+
{"version":3,"file":"drawer.d.ts","sourceRoot":"","sources":["../../../../src/custom-elements/drawer/css/drawer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAC;AAErC,eAAO,MAAM,WAAW,EAAE,SAuBzB,CAAC"}
|
|
@@ -9,6 +9,17 @@ export const drawerStyle = css `
|
|
|
9
9
|
box-sizing: border-box;
|
|
10
10
|
border: 3px #303030 solid;
|
|
11
11
|
border-radius: 20px;
|
|
12
|
+
height: auto;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.closed {
|
|
16
|
+
max-height: 0px;
|
|
17
|
+
transition: max-height 1.4s ease-out;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.opened {
|
|
21
|
+
max-height: 100%;
|
|
22
|
+
transition: max-height 1.4s ease-out;
|
|
12
23
|
}
|
|
13
24
|
|
|
14
25
|
`;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"visibility.d.ts","sourceRoot":"","sources":["../../../../../src/custom-elements/drawer/css/old/visibility.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAC;AAErC,eAAO,MAAM,UAAU,EAAE,SAoBxB,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { css } from "lit";
|
|
2
|
+
export const visibility = css `
|
|
3
|
+
|
|
4
|
+
.visibility[on] {
|
|
5
|
+
visibility: visible;
|
|
6
|
+
transform: translate3d(0, 0, 0);
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.visibility {
|
|
10
|
+
position: fixed;
|
|
11
|
+
top: 0;
|
|
12
|
+
left: 0;
|
|
13
|
+
right: 0;
|
|
14
|
+
visibility: hidden;
|
|
15
|
+
will-change: transform;
|
|
16
|
+
transform: translate3d(0, -150%, 0);
|
|
17
|
+
transition-property: visibility, transform;
|
|
18
|
+
transition-duration: 1.4s;
|
|
19
|
+
display: block;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
`;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"paragraph.d.ts","sourceRoot":"","sources":["../../../../src/custom-elements/drawer/css/paragraph.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAC;AAErC,eAAO,MAAM,SAAS,EAAE,
|
|
1
|
+
{"version":3,"file":"paragraph.d.ts","sourceRoot":"","sources":["../../../../src/custom-elements/drawer/css/paragraph.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAC;AAErC,eAAO,MAAM,SAAS,EAAE,SAQvB,CAAC"}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { css } from "lit";
|
|
2
2
|
export const lineStyle = css `
|
|
3
|
-
|
|
4
|
-
p {
|
|
3
|
+
|
|
4
|
+
.setLog > p {
|
|
5
|
+
margin: 12px;
|
|
6
|
+
box-sizing: border-box;
|
|
5
7
|
text-align: center;
|
|
6
8
|
}
|
|
7
|
-
|
|
8
|
-
.setLog > p { margin: 12px; box-sizing: border-box; }
|
|
9
|
-
.divide { border: 2px solid #606060; margin: 6px 0 0 0; border-radius: 50%; }
|
|
10
9
|
|
|
11
10
|
`;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"visibility.d.ts","sourceRoot":"","sources":["../../../../src/custom-elements/drawer/css/visibility.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAC;AAErC,eAAO,MAAM,UAAU,EAAE,
|
|
1
|
+
{"version":3,"file":"visibility.d.ts","sourceRoot":"","sources":["../../../../src/custom-elements/drawer/css/visibility.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAC;AAErC,eAAO,MAAM,UAAU,EAAE,SAsBxB,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { css } from "lit";
|
|
2
2
|
export const visibility = css `
|
|
3
|
-
|
|
3
|
+
/*
|
|
4
4
|
.visibility[on] {
|
|
5
5
|
visibility: visible;
|
|
6
6
|
transform: translate3d(0, 0, 0);
|
|
@@ -15,8 +15,10 @@ export const visibility = css `
|
|
|
15
15
|
will-change: transform;
|
|
16
16
|
transform: translate3d(0, -150%, 0);
|
|
17
17
|
transition-property: visibility, transform;
|
|
18
|
-
transition-duration: 1.4s;
|
|
19
18
|
display: block;
|
|
20
19
|
}
|
|
20
|
+
*/
|
|
21
|
+
/* max-height is a programmed transition effect */
|
|
22
|
+
|
|
21
23
|
|
|
22
24
|
`;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"drawer.d.ts","sourceRoot":"","sources":["../../../src/custom-elements/drawer/drawer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,cAAc,EAAQ,UAAU,EAAE,MAAoB,KAAK,CAAC;AAG1E,OAAO,EAAS,QAAQ,EAAE,MAAqB,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"drawer.d.ts","sourceRoot":"","sources":["../../../src/custom-elements/drawer/drawer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,cAAc,EAAQ,UAAU,EAAE,MAAoB,KAAK,CAAC;AAG1E,OAAO,EAAS,QAAQ,EAAE,MAAqB,aAAa,CAAC;AAa7D,OAAO,eAAe,CAAC;AACvB,OAAO,iBAAiB,CAAC;;;;;;;;;;;;;;AAEzB,qBACa,UAAW,SAAQ,eAA0B;IAGf,OAAO,CAAC,GAAG,CAAM;IAGO,MAAM,UAAS;IAGf,QAAQ,UAAS;IAEzE,OAAO,CAAC,KAAK,CAAa;IAC1B,OAAO,CAAC,IAAI,CAAiB;IAC7B,OAAO,CAAC,KAAK,CAAgB;;IAMtC,YAAY,CAAC,KAAK,EAAE,QAAQ;IAO5B,SAAS,CAAC,YAAY;IAatB,MAAM,KAAK,MAAM,IAAI,cAAc,CA0ChC;IAEH,SAAS,CAAC,MAAM;CA+CjB;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC3B,aAAa,EAAE,UAAU,CAAC;KAC7B;CACF"}
|
|
@@ -10,7 +10,6 @@ import { connect } from 'pwa-helpers/connect-mixin';
|
|
|
10
10
|
import { store } from '../../store';
|
|
11
11
|
import { close } from '../../css/svg';
|
|
12
12
|
import { show } from '../../css/toggle';
|
|
13
|
-
import { visibility } from './css/visibility';
|
|
14
13
|
import { drawerStyle } from './css/drawer';
|
|
15
14
|
import { exitStyle } from './css/exit';
|
|
16
15
|
import { linkStyle } from './css/link';
|
|
@@ -50,7 +49,6 @@ let UserDrawer = class UserDrawer extends connect(store)(LitElement) {
|
|
|
50
49
|
static get styles() {
|
|
51
50
|
return [
|
|
52
51
|
show,
|
|
53
|
-
visibility,
|
|
54
52
|
drawerStyle,
|
|
55
53
|
exitStyle,
|
|
56
54
|
linkStyle,
|
|
@@ -64,19 +62,29 @@ let UserDrawer = class UserDrawer extends connect(store)(LitElement) {
|
|
|
64
62
|
top: 0;
|
|
65
63
|
left: 0;
|
|
66
64
|
right: 0;
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
transition-
|
|
71
|
-
|
|
72
|
-
|
|
65
|
+
overflow: hidden;
|
|
66
|
+
|
|
67
|
+
transition-property: max-height;
|
|
68
|
+
transition-duration: 1.4s;
|
|
69
|
+
height: auto;
|
|
70
|
+
max-height: 0px;
|
|
71
|
+
transition: max-height 1.5s ease-out;
|
|
72
|
+
|
|
73
73
|
display: block;
|
|
74
|
+
padding-top: env(safe-area-inset-top);
|
|
74
75
|
}
|
|
75
76
|
|
|
77
|
+
/*visibility: hidden;
|
|
78
|
+
/*will-change: transform;
|
|
79
|
+
transform: translate3d(0, -150%, 0);
|
|
80
|
+
transition-property: visibility, transform;*/
|
|
81
|
+
|
|
82
|
+
/*transform: translate3d(0, 0, 0);*/
|
|
83
|
+
|
|
76
84
|
:host([drawer]) {
|
|
77
85
|
transition-duration: 1.4s;
|
|
78
|
-
|
|
79
|
-
|
|
86
|
+
max-height: 100%;
|
|
87
|
+
transition: max-height 1.5s ease-out;
|
|
80
88
|
}
|
|
81
89
|
|
|
82
90
|
`
|
|
@@ -88,8 +96,7 @@ let UserDrawer = class UserDrawer extends connect(store)(LitElement) {
|
|
|
88
96
|
|
|
89
97
|
<!-- Drawer Wrapper -->
|
|
90
98
|
<section
|
|
91
|
-
class="
|
|
92
|
-
?on="${this.drawer === true}">
|
|
99
|
+
class="userDrawer ${this.drawer ? 'opened' : 'closed'}">
|
|
93
100
|
|
|
94
101
|
<!-- Exit Button -->
|
|
95
102
|
<header class="exit">
|
|
@@ -106,7 +113,6 @@ let UserDrawer = class UserDrawer extends connect(store)(LitElement) {
|
|
|
106
113
|
<!-- Log-in State -->
|
|
107
114
|
<user-log-in
|
|
108
115
|
class="spec"
|
|
109
|
-
|
|
110
116
|
?on="${true === this._sign ? !this.register : this.register}"></user-log-in>
|
|
111
117
|
|
|
112
118
|
<!-- Sign-up State -->
|