pwa-auth 2.0.8 → 3.0.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.
Files changed (188) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/README.md +37 -18
  3. package/demonstration/compiled/pwa-auth.js +880 -0
  4. package/{demo → demonstration}/index.html +1 -1
  5. package/package.json +8 -7
  6. package/pwa-auth.js +4 -3
  7. package/{website → src}/THIRD_PARTY_LICENSES.txt +56 -56
  8. package/src/compiled/pwa-auth.js +880 -0
  9. package/src-typescript/css/toggle.ts +9 -0
  10. package/src-typescript/development/junk/firebase-object.ts +49 -0
  11. package/src-typescript/development/junk/notes.md +96 -0
  12. package/src-typescript/development/junk/phone.ts +146 -0
  13. package/src-typescript/development/junk/photo.ts +440 -0
  14. package/src-typescript/development/junk/telephone.ts +282 -0
  15. package/{source/firebase/firebase-login.ts → src-typescript/development/login.ts} +1 -1
  16. package/{source/firebase/firebase.ts → src-typescript/development/object.ts} +1 -1
  17. package/src-typescript/firebase/authentication.ts +11 -0
  18. package/{source/firebase/start.ts → src-typescript/firebase/interface.ts} +35 -64
  19. package/{source/custom-elements → src-typescript/webcomponents}/drawer/drawer.ts +1 -1
  20. package/{source/custom-elements → src-typescript/webcomponents}/drawer/input/forgot.ts +1 -1
  21. package/{source/custom-elements → src-typescript/webcomponents}/drawer/input/login.ts +1 -1
  22. package/{source/custom-elements → src-typescript/webcomponents}/drawer/input/sign-up.ts +2 -1
  23. package/{deploy/custom-elements/icon/css/icon.js → src-typescript/webcomponents/icon/css/icon.ts} +4 -3
  24. package/{source/custom-elements → src-typescript/webcomponents}/icon/icon.ts +2 -21
  25. package/{source/custom-elements → src-typescript/webcomponents}/settings/input/delete.ts +1 -1
  26. package/{source/custom-elements → src-typescript/webcomponents}/settings/input/email.ts +1 -1
  27. package/{source/custom-elements → src-typescript/webcomponents}/settings/input/images.ts +1 -1
  28. package/{source/custom-elements → src-typescript/webcomponents}/settings/input/name.ts +1 -1
  29. package/{source/custom-elements → src-typescript/webcomponents}/settings/input/password.ts +1 -1
  30. package/{source/custom-elements → src-typescript/webcomponents}/settings/input/uploader.ts +1 -1
  31. package/{source/custom-elements → src-typescript/webcomponents}/settings/settings.ts +2 -2
  32. package/deploy/css/default.d.ts +0 -5
  33. package/deploy/css/default.d.ts.map +0 -1
  34. package/deploy/css/default.js +0 -99
  35. package/deploy/css/font.d.ts +0 -2
  36. package/deploy/css/font.d.ts.map +0 -1
  37. package/deploy/css/font.js +0 -16
  38. package/deploy/css/form/button.d.ts +0 -3
  39. package/deploy/css/form/button.d.ts.map +0 -1
  40. package/deploy/css/form/button.js +0 -54
  41. package/deploy/css/form/input.d.ts +0 -3
  42. package/deploy/css/form/input.d.ts.map +0 -1
  43. package/deploy/css/form/input.js +0 -24
  44. package/deploy/css/form/label.d.ts +0 -3
  45. package/deploy/css/form/label.d.ts.map +0 -1
  46. package/deploy/css/form/label.js +0 -22
  47. package/deploy/css/form/list.d.ts +0 -3
  48. package/deploy/css/form/list.d.ts.map +0 -1
  49. package/deploy/css/form/list.js +0 -22
  50. package/deploy/css/svg.d.ts +0 -4
  51. package/deploy/css/svg.d.ts.map +0 -1
  52. package/deploy/css/svg.js +0 -4
  53. package/deploy/css/toggle.d.ts +0 -2
  54. package/deploy/css/toggle.d.ts.map +0 -1
  55. package/deploy/css/toggle.js +0 -8
  56. package/deploy/custom-elements/drawer/css/drawer.d.ts +0 -3
  57. package/deploy/custom-elements/drawer/css/drawer.d.ts.map +0 -1
  58. package/deploy/custom-elements/drawer/css/drawer.js +0 -55
  59. package/deploy/custom-elements/drawer/css/exit.d.ts +0 -3
  60. package/deploy/custom-elements/drawer/css/exit.d.ts.map +0 -1
  61. package/deploy/custom-elements/drawer/css/exit.js +0 -48
  62. package/deploy/custom-elements/drawer/css/link.d.ts +0 -3
  63. package/deploy/custom-elements/drawer/css/link.d.ts.map +0 -1
  64. package/deploy/custom-elements/drawer/css/link.js +0 -12
  65. package/deploy/custom-elements/drawer/css/paragraph.d.ts +0 -3
  66. package/deploy/custom-elements/drawer/css/paragraph.d.ts.map +0 -1
  67. package/deploy/custom-elements/drawer/css/paragraph.js +0 -10
  68. package/deploy/custom-elements/drawer/css/toggle.d.ts +0 -3
  69. package/deploy/custom-elements/drawer/css/toggle.d.ts.map +0 -1
  70. package/deploy/custom-elements/drawer/css/toggle.js +0 -18
  71. package/deploy/custom-elements/drawer/drawer.d.ts +0 -37
  72. package/deploy/custom-elements/drawer/drawer.d.ts.map +0 -1
  73. package/deploy/custom-elements/drawer/drawer.js +0 -128
  74. package/deploy/custom-elements/drawer/input/forgot.d.ts +0 -16
  75. package/deploy/custom-elements/drawer/input/forgot.d.ts.map +0 -1
  76. package/deploy/custom-elements/drawer/input/forgot.js +0 -60
  77. package/deploy/custom-elements/drawer/input/login.d.ts +0 -20
  78. package/deploy/custom-elements/drawer/input/login.d.ts.map +0 -1
  79. package/deploy/custom-elements/drawer/input/login.js +0 -128
  80. package/deploy/custom-elements/drawer/input/sign-up.d.ts +0 -20
  81. package/deploy/custom-elements/drawer/input/sign-up.d.ts.map +0 -1
  82. package/deploy/custom-elements/drawer/input/sign-up.js +0 -137
  83. package/deploy/custom-elements/icon/css/icon.d.ts +0 -2
  84. package/deploy/custom-elements/icon/css/icon.d.ts.map +0 -1
  85. package/deploy/custom-elements/icon/icon.d.ts +0 -33
  86. package/deploy/custom-elements/icon/icon.d.ts.map +0 -1
  87. package/deploy/custom-elements/icon/icon.js +0 -72
  88. package/deploy/custom-elements/settings/css/navigation.d.ts +0 -2
  89. package/deploy/custom-elements/settings/css/navigation.d.ts.map +0 -1
  90. package/deploy/custom-elements/settings/css/navigation.js +0 -51
  91. package/deploy/custom-elements/settings/input/delete.d.ts +0 -34
  92. package/deploy/custom-elements/settings/input/delete.d.ts.map +0 -1
  93. package/deploy/custom-elements/settings/input/delete.js +0 -87
  94. package/deploy/custom-elements/settings/input/email.d.ts +0 -34
  95. package/deploy/custom-elements/settings/input/email.d.ts.map +0 -1
  96. package/deploy/custom-elements/settings/input/email.js +0 -98
  97. package/deploy/custom-elements/settings/input/images.d.ts +0 -2
  98. package/deploy/custom-elements/settings/input/images.d.ts.map +0 -1
  99. package/deploy/custom-elements/settings/input/images.js +0 -22
  100. package/deploy/custom-elements/settings/input/name.d.ts +0 -33
  101. package/deploy/custom-elements/settings/input/name.d.ts.map +0 -1
  102. package/deploy/custom-elements/settings/input/name.js +0 -90
  103. package/deploy/custom-elements/settings/input/password.d.ts +0 -36
  104. package/deploy/custom-elements/settings/input/password.d.ts.map +0 -1
  105. package/deploy/custom-elements/settings/input/password.js +0 -145
  106. package/deploy/custom-elements/settings/input/uploader.d.ts +0 -37
  107. package/deploy/custom-elements/settings/input/uploader.d.ts.map +0 -1
  108. package/deploy/custom-elements/settings/input/uploader.js +0 -225
  109. package/deploy/custom-elements/settings/settings.d.ts +0 -37
  110. package/deploy/custom-elements/settings/settings.d.ts.map +0 -1
  111. package/deploy/custom-elements/settings/settings.js +0 -197
  112. package/deploy/firebase/firebase-login.d.ts +0 -21
  113. package/deploy/firebase/firebase-login.d.ts.map +0 -1
  114. package/deploy/firebase/firebase-login.js +0 -85
  115. package/deploy/firebase/firebase.d.ts +0 -20
  116. package/deploy/firebase/firebase.d.ts.map +0 -1
  117. package/deploy/firebase/firebase.js +0 -76
  118. package/deploy/firebase/start.d.ts +0 -14
  119. package/deploy/firebase/start.d.ts.map +0 -1
  120. package/deploy/firebase/start.js +0 -86
  121. package/deploy/lazy-loader.d.ts +0 -11
  122. package/deploy/lazy-loader.d.ts.map +0 -1
  123. package/deploy/lazy-loader.js +0 -20
  124. package/deploy/redux/backend.d.ts +0 -16
  125. package/deploy/redux/backend.d.ts.map +0 -1
  126. package/deploy/redux/backend.js +0 -43
  127. package/deploy/redux/drawer.d.ts +0 -18
  128. package/deploy/redux/drawer.d.ts.map +0 -1
  129. package/deploy/redux/drawer.js +0 -21
  130. package/deploy/redux/frontend.d.ts +0 -17
  131. package/deploy/redux/frontend.d.ts.map +0 -1
  132. package/deploy/redux/frontend.js +0 -67
  133. package/deploy/redux/object.d.ts +0 -24
  134. package/deploy/redux/object.d.ts.map +0 -1
  135. package/deploy/redux/object.js +0 -1
  136. package/deploy/store.d.ts +0 -19
  137. package/deploy/store.d.ts.map +0 -1
  138. package/deploy/store.js +0 -13
  139. package/npm/THIRD_PARTY_LICENSES.txt +0 -303
  140. package/npm/pwa-auth.js +0 -306
  141. package/source/css/toggle.ts +0 -9
  142. package/source/custom-elements/icon/css/icon.ts +0 -70
  143. package/website/404.html +0 -33
  144. package/website/css/pwa-styles.css +0 -36
  145. package/website/css/styles.css +0 -48
  146. package/website/images/empty.jpg +0 -0
  147. package/website/images/favicon.ico +0 -0
  148. package/website/images/manifest/logo-144.png +0 -0
  149. package/website/images/manifest/logo-192.png +0 -0
  150. package/website/images/manifest/logo-48.png +0 -0
  151. package/website/images/manifest/logo-512.png +0 -0
  152. package/website/images/manifest/logo-72.png +0 -0
  153. package/website/images/manifest/logo-96.png +0 -0
  154. package/website/images/manifest/maskable_icon_x128.png +0 -0
  155. package/website/images/manifest/maskable_icon_x192.png +0 -0
  156. package/website/images/manifest/maskable_icon_x384.png +0 -0
  157. package/website/images/manifest/maskable_icon_x48.png +0 -0
  158. package/website/images/manifest/maskable_icon_x512.png +0 -0
  159. package/website/images/manifest/maskable_icon_x72.png +0 -0
  160. package/website/images/manifest/maskable_icon_x96.png +0 -0
  161. package/website/index.html +0 -69
  162. package/website/js/images/empty.jpg +0 -0
  163. package/website/js/pwa-auth.js +0 -306
  164. package/website/sitemap.xml +0 -11
  165. /package/{demo → demonstration}/css/pwa-styles.css +0 -0
  166. /package/{demo → demonstration}/css/styles.css +0 -0
  167. /package/{demo → demonstration}/images/empty.jpg +0 -0
  168. /package/{npm → src}/empty.jpg +0 -0
  169. /package/{npm → src}/pwa-styles.css +0 -0
  170. /package/{source → src-typescript}/css/default.ts +0 -0
  171. /package/{source → src-typescript}/css/font.ts +0 -0
  172. /package/{source → src-typescript}/css/form/button.ts +0 -0
  173. /package/{source → src-typescript}/css/form/input.ts +0 -0
  174. /package/{source → src-typescript}/css/form/label.ts +0 -0
  175. /package/{source → src-typescript}/css/form/list.ts +0 -0
  176. /package/{source → src-typescript}/css/svg.ts +0 -0
  177. /package/{source → src-typescript}/lazy-loader.ts +0 -0
  178. /package/{source → src-typescript}/redux/backend.ts +0 -0
  179. /package/{source → src-typescript}/redux/drawer.ts +0 -0
  180. /package/{source → src-typescript}/redux/frontend.ts +0 -0
  181. /package/{source → src-typescript}/redux/object.ts +0 -0
  182. /package/{source → src-typescript}/store.ts +0 -0
  183. /package/{source/custom-elements → src-typescript/webcomponents}/drawer/css/drawer.ts +0 -0
  184. /package/{source/custom-elements → src-typescript/webcomponents}/drawer/css/exit.ts +0 -0
  185. /package/{source/custom-elements → src-typescript/webcomponents}/drawer/css/link.ts +0 -0
  186. /package/{source/custom-elements → src-typescript/webcomponents}/drawer/css/paragraph.ts +0 -0
  187. /package/{source/custom-elements → src-typescript/webcomponents}/drawer/css/toggle.ts +0 -0
  188. /package/{source/custom-elements → src-typescript/webcomponents}/settings/css/navigation.ts +0 -0
@@ -14,7 +14,7 @@ import {
14
14
  sendEmailVerification
15
15
  } from "firebase/auth";
16
16
 
17
- import { auth, user } from "./start";
17
+ import { auth, user } from "../firebase/authentication";
18
18
 
19
19
  interface baseVerify {
20
20
  verifyPasswordResetCode : any,
@@ -12,7 +12,7 @@ import {
12
12
  UserCredential
13
13
  } from "firebase/auth";
14
14
 
15
- import { auth } from "./start";
15
+ import { auth } from "../firebase/authentication";
16
16
  import { FirebaseError } from "firebase/app";
17
17
 
18
18
  interface base {
@@ -0,0 +1,11 @@
1
+ import { initializeApp, FirebaseApp } from 'firebase/app';
2
+ import { getFirestore, Firestore } from "firebase/firestore";
3
+ import { getStorage, FirebaseStorage } from "@firebase/storage";
4
+ import { getAuth, Auth, User } from 'firebase/auth';
5
+ // Memory Reference to Services - Object Type
6
+ export const firebaseConfig = JSON.parse(process.env.FIREBASE_CONFIG || "{}");
7
+ export const application : FirebaseApp = initializeApp(firebaseConfig);
8
+ export const db : Firestore = getFirestore(application);
9
+ export const storage : FirebaseStorage = getStorage(application);
10
+ export const auth : Auth = getAuth(application);
11
+ export const user : User | null = auth.currentUser;
@@ -1,22 +1,21 @@
1
1
  // Representational State Transfer - Application Programming Interface
2
+
3
+
4
+
2
5
  // Module Imports ---------------- ---------------- ----------------
3
6
 
7
+
8
+
4
9
  // Redux
5
10
  import { store } from '../store';
6
11
  import { closeSign, iconAuth, nameAuth, userAuth } from '../redux/frontend';
7
12
  import { accID, accEmail, accImage, accName } from '../redux/backend';
8
13
 
9
- // Firebase App
10
- import { FirebaseApp, initializeApp } from 'firebase/app';
11
-
12
14
  // Firebase Auth
13
- import { Auth, User, getAuth, onAuthStateChanged, sendEmailVerification, signOut } from 'firebase/auth';
15
+ import { getAuth, onAuthStateChanged, sendEmailVerification, signOut } from 'firebase/auth';
14
16
 
15
17
  // Firebase Firestore
16
- import { getFirestore, Firestore, doc, deleteDoc } from "firebase/firestore";
17
-
18
- // Firebase Storage
19
- import { getStorage, FirebaseStorage } from "@firebase/storage";
18
+ import { doc, deleteDoc } from "firebase/firestore";
20
19
 
21
20
  //Firebase Analytics
22
21
  import { Analytics, getAnalytics, logEvent } from "firebase/analytics";
@@ -24,25 +23,17 @@ import { Analytics, getAnalytics, logEvent } from "firebase/analytics";
24
23
  // Firebse Messaginmg
25
24
  import { isSupported } from "firebase/messaging";
26
25
 
26
+ // Start Authentication
27
+ import { application, auth, db } from './authentication'
27
28
 
28
-
29
- // Module Exports ---------------- ---------------- ----------------
30
-
29
+ // LANGUAGE
30
+ getAuth().useDeviceLanguage();
31
31
 
32
32
 
33
- const firebaseConfig: any = JSON.parse(process.env.FIREBASE_CONFIG || "{}");
34
33
 
35
- // Memory Reference to Services - Object Type
36
- export const application : FirebaseApp = initializeApp(firebaseConfig); // Initialize Application
37
- export const db : Firestore = getFirestore(application); // Initialize Database
38
- export const storage : FirebaseStorage = getStorage(application); // Reference: Represents a reference to a file or directory in Storage, returned by ref(). // UploadTask: Represents an ongoing upload operation, returned by upload methods. // ListResult: Represents the result of listing files in a directory.
39
- export const auth : Auth = getAuth(application);
40
- export const user : User | null = auth.currentUser;
34
+ // START ANALYTICS ----------------
41
35
 
42
- // LANGUAGE
43
- getAuth().useDeviceLanguage();
44
36
 
45
- // START ANALYTICS ----------------
46
37
 
47
38
  // const analytics : Analytics = getAnalytics();
48
39
  let analytics: Analytics;
@@ -58,10 +49,16 @@ let analytics: Analytics;
58
49
  }
59
50
  })();
60
51
 
52
+
53
+
61
54
  // END ANALYTICS ----------------
62
55
 
56
+
57
+
63
58
  // Start Support Checks
64
59
 
60
+
61
+
65
62
  // Check for Service Worker support
66
63
  if ('serviceWorker' in navigator) { console.log('Service Worker is supported'); }
67
64
  else { console.log('Service Worker is not supported'); }
@@ -70,10 +67,16 @@ else { console.log('Service Worker is not supported'); }
70
67
  if ('PushManager' in window) { console.log('Push API is supported'); }
71
68
  else { console.log('Push API is not supported'); }
72
69
 
70
+
71
+
73
72
  // End Support Checks
74
73
 
74
+
75
+
75
76
  // Start Distribute Information ---------------- ----------------
76
77
 
78
+
79
+
77
80
  // Flag to track if an email change is pending verification
78
81
  let pendingEmailVerification = false;
79
82
 
@@ -111,6 +114,7 @@ onAuthStateChanged(auth, (user) => {
111
114
 
112
115
  // Email Change Listener - Custom Event
113
116
  if (pendingEmailVerification && !user.emailVerified) {
117
+
114
118
  // Send verification email for the updated email
115
119
  sendEmailVerification(user)
116
120
  .then(() => {
@@ -121,8 +125,10 @@ onAuthStateChanged(auth, (user) => {
121
125
  console.error("Error sending verification email:", error.message);
122
126
  pendingEmailVerification = false; // Reset flag on error
123
127
  });
128
+
124
129
  } else if (user.emailVerified) {
125
130
  console.log("User's email is already verified:"/*, user.email*/);
131
+
126
132
  } else {
127
133
  console.log("User signed in, no email verification pending:"/*, user.email*/);
128
134
  }
@@ -161,56 +167,21 @@ onAuthStateChanged(auth, (user) => {
161
167
 
162
168
  });
163
169
 
164
- // End Distribute Informatiom ---------------- ----------------
165
-
166
- // Exact Name Reference - Firebase Action
167
- export const logOut = async () => { return signOut(auth); };
168
- export const logAccount = async () => { logEvent(analytics, 'create_account'); };
169
- export const logAccountDelete = async () => { logEvent(analytics, 'delete_account'); };
170
- export const deleteDocument = async (collect:string, item:string) => {
171
-
172
- await deleteDoc(doc(db, collect, item));
173
-
174
- };
175
170
 
176
171
 
172
+ // End Distribute Informatiom ---------------- ----------------
177
173
 
178
174
 
179
175
 
180
- /*
181
- // Object Initializer Notation
182
- export interface fire {
183
- apiKey: string,
184
- authDomain: string,
185
- databaseURL: string,
186
- projectId: string,
187
- storageBucket: string,
188
- messagingSenderId: string,
189
- appId: string,
190
- measurementId: string
191
- };
176
+ // Module Exports ---------------- Exact Name Reference ---------------- Firebase Action
192
177
 
193
178
 
194
- // Initialize Firebase Data
195
- const admin: fire = {
196
- appId: connect.appId,
197
- apiKey: connect.apiKey,
198
- authDomain: connect.authDomain,
199
- databaseURL: connect.databaseURL,
200
- projectId: connect.projectId,
201
- storageBucket: connect.storageBucket,
202
- messagingSenderId: connect.messagingSenderId,
203
- measurementId: connect.measurementId
204
- };
205
- */
206
179
 
180
+ export const logOut = async () => { return signOut(auth); };
181
+ export const logAccount = async () => { logEvent(analytics, 'create_account'); };
182
+ export const logAccountDelete = async () => { logEvent(analytics, 'delete_account'); };
183
+ export const deleteDocument = async (collect:string, item:string) => {
207
184
 
208
- /*
209
- window.connect = {};
185
+ await deleteDoc(doc(db, collect, item));
210
186
 
211
- declare global {
212
- interface Window {
213
- connect: any;
214
- }
215
- }
216
- */
187
+ };
@@ -12,7 +12,7 @@ import { lineStyle } from './css/paragraph';
12
12
  import { listStyle } from '../../css/form/list';
13
13
 
14
14
  import { toggleSign } from '../../redux/frontend';
15
- import { logOut } from '../../firebase/start';
15
+ import { logOut } from '../../firebase/interface';
16
16
 
17
17
  import './input/login';
18
18
  import './input/sign-up';
@@ -4,7 +4,7 @@ import { html, TemplateResult, } from 'lit';
4
4
  import { customElement, state } from "lit/decorators.js"
5
5
  import { LazyLoader } from '../../../lazy-loader';
6
6
  import { sendPasswordResetEmail/*, verifyPasswordResetCode*/ } from 'firebase/auth';
7
- import { auth } from '../../../firebase/start';
7
+ import { auth } from '../../../firebase/authentication';
8
8
 
9
9
  @customElement('reset-email')
10
10
  export class ResetEmail extends LazyLoader {
@@ -2,7 +2,7 @@ import { html, LitElement, css } from 'lit';
2
2
  import { customElement, state } from 'lit/decorators.js';
3
3
 
4
4
  import { EmailAuthProvider, signInWithCredential } from 'firebase/auth';
5
- import { auth } from '../../../firebase/start';
5
+ import { auth } from '../../../firebase/authentication';
6
6
 
7
7
  import { buttonStyle } from '../../../css/form/button';
8
8
  import { labelStyle } from '../../../css/form/label';
@@ -2,7 +2,8 @@ import { css, html, LitElement } from 'lit';
2
2
  import { customElement, state } from 'lit/decorators.js';
3
3
 
4
4
  import { createUserWithEmailAndPassword, sendEmailVerification } from 'firebase/auth';
5
- import { auth, logAccount } from '../../../firebase/start';
5
+ import { auth } from '../../../firebase/authentication';
6
+ import { logAccount } from '../../../firebase/interface';
6
7
 
7
8
  import { buttonStyle } from '../../../css/form/button';
8
9
  import { labelStyle } from '../../../css/form/label';
@@ -1,5 +1,6 @@
1
- import { css } from 'lit';
2
- export const iconStyles = css `
1
+ import { css } from 'lit';
2
+
3
+ export const iconStyles = css`
3
4
 
4
5
  :host {
5
6
  margin: auto;
@@ -56,4 +57,4 @@ export const iconStyles = css `
56
57
  margin: auto;
57
58
  }
58
59
 
59
- `;
60
+ `;
@@ -25,6 +25,7 @@ export class UserIcon extends connect(store)(LitElement) {
25
25
  this.shadowRoot!.querySelector('.toggles')!.addEventListener('click', () => {
26
26
  // console.log('logged-in: ',this._user);
27
27
  store.dispatch(toggleSign());
28
+ console.log('here');
28
29
  } );
29
30
  }
30
31
 
@@ -67,24 +68,4 @@ declare global {
67
68
  interface HTMLElementTagNameMap {
68
69
  'user-icon': UserIcon;
69
70
  }
70
- }
71
-
72
- /*
73
- <!--
74
- -->
75
- <!--
76
- \${ this._user
77
- \? html\`
78
- <div
79
- class = "iconArea">
80
- <input
81
- type = "image"
82
- class = "userImage"
83
- alt = "Login"
84
- height = "32px"
85
- width = "32px"
86
- src = "\${this._photoURL}"><!-- id = "image"
87
- </div>
88
- \`
89
- \: faceIcon }-->
90
- */
71
+ }
@@ -3,7 +3,7 @@ import { state } from "lit/decorators.js";
3
3
  import { connect } from "pwa-helpers";
4
4
  import store, { AppState } from "../../../store";
5
5
  import { buttonStyle } from "../../../css/form/button";
6
- import { auth } from '../../../firebase/start';
6
+ import { auth } from '../../../firebase/authentication';
7
7
 
8
8
  export class DeleteUser extends connect(store)(LitElement) {
9
9
 
@@ -2,7 +2,7 @@ import { CSSResultArray, LitElement, css, html } from "lit";
2
2
  import { property, state } from "lit/decorators.js";
3
3
  import { connect } from "pwa-helpers";
4
4
  import store, { AppState } from "../../../store";
5
- import { auth } from "../../../firebase/start";
5
+ import { auth } from "../../../firebase/authentication";
6
6
  import { labelStyle } from "../../../css/form/label";
7
7
  import { inputStyle } from "../../../css/form/input";
8
8
  import { buttonStyle } from "../../../css/form/button";
@@ -1,5 +1,5 @@
1
1
  import { ref } from "@firebase/storage";
2
- import { storage } from "../../../firebase/start";
2
+ import { storage } from "../../../firebase/authentication";
3
3
  /*
4
4
  export const uploadIcon = (uploader, file) => {
5
5
 
@@ -4,7 +4,7 @@ import { connect } from "pwa-helpers";
4
4
  import { store, AppState } from "../../../store";
5
5
  import { updateProfile } from "firebase/auth";
6
6
  import { accName } from "../../../redux/backend";
7
- import { auth } from "../../../firebase/start";
7
+ import { auth } from "../../../firebase/authentication";
8
8
  import { labelStyle } from "../../../css/form/label";
9
9
  import { inputStyle } from "../../../css/form/input";
10
10
  import { buttonStyle } from "../../../css/form/button";
@@ -3,7 +3,7 @@ import { CSSResultArray, LitElement, css, html } from "lit";
3
3
  import { state } from "lit/decorators.js";
4
4
  import { connect } from "pwa-helpers";
5
5
  import store, { AppState } from "../../../store";
6
- import { auth } from "../../../firebase/start";
6
+ import { auth } from "../../../firebase/authentication";
7
7
  import { labelStyle } from "../../../css/form/label";
8
8
  import { inputStyle } from "../../../css/form/input";
9
9
  import { buttonStyle } from "../../../css/form/button";
@@ -3,7 +3,7 @@ import { html, css, LitElement, CSSResultArray } from 'lit';
3
3
  import { property, state } from 'lit/decorators.js';
4
4
  import { store, AppState } from '../../../store';
5
5
  import { connect } from 'pwa-helpers';
6
- import { auth, storage, user } from '../../../firebase/start';
6
+ import { auth, storage, user } from '../../../firebase/authentication';
7
7
  import { updateProfile } from 'firebase/auth';
8
8
  import { accImage } from '../../../redux/backend';
9
9
  import { ref, updateMetadata, getDownloadURL, uploadBytesResumable } from "@firebase/storage";
@@ -1,4 +1,4 @@
1
- import { css, html, LitElement } from 'lit';
1
+ import { css, CSSResultArray, html, LitElement } from 'lit';
2
2
  import { state, customElement, property } from 'lit/decorators.js';
3
3
  import { connect } from 'pwa-helpers/connect-mixin.js';
4
4
  import { store, AppState } from '../../store';
@@ -57,7 +57,7 @@ export class UserSettings extends connect(store)(LitElement) {
57
57
  this.name = state.backend!.name; // Username
58
58
  }
59
59
 
60
- static get styles() { return [
60
+ static get styles():CSSResultArray { return [
61
61
  navigation,
62
62
  listStyle,
63
63
  css`
@@ -1,5 +0,0 @@
1
- export declare const iconRoot: import("lit").CSSResult;
2
- export declare const drawerRoot: import("lit").CSSResult;
3
- export declare const settingsRoot: import("lit").CSSResult;
4
- export declare const themeRoot: import("lit").CSSResult;
5
- //# sourceMappingURL=default.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"default.d.ts","sourceRoot":"","sources":["../../source/css/default.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,QAAQ,yBA4BpB,CAAC;AAEF,eAAO,MAAM,UAAU,yBAyBtB,CAAC;AAEF,eAAO,MAAM,YAAY,yBAiCxB,CAAC;AAUF,eAAO,MAAM,SAAS,yBAQrB,CAAC"}
@@ -1,99 +0,0 @@
1
- import { css } from "lit";
2
- export const iconRoot = css `
3
-
4
- /* CSS: Custom Variables: <head> tag */
5
-
6
- :root {
7
-
8
- /* WebComponent 1 : User Icon
9
- <user-icon>
10
- <button> */
11
- --pwa_icon_hover: lightgrey; /* custom-elements Folder > icon Folder > CSS Folder > icon.ts */
12
- --pwa_icon_background: #6cc04a; /* custom-elements Folder > icon Folder > CSS Folder > icon.ts */
13
- --pwa_icon_border: 2px solid black; /* custom-elements Folder > icon Folder > CSS Folder > icon.ts */
14
-
15
- /* WebComponent 1: logged-out
16
- <user-icon>
17
- <button class="login"> */
18
- --pwa_icon_height: 32px; /* sync to --pwa_icon_diameter */ /* custom-elements Folder > icon Folder > CSS Folder > icon.ts */
19
- --pwa_icon_padding: 0px 16px; /* custom-elements Folder > icon Folder > CSS Folder > icon.ts */
20
- --pwa_icon_radius: 6px; /* custom-elements Folder > icon Folder > CSS Folder > icon.ts */
21
- --pwa_icon_font: 'Arial', sans-serif; /* custom-elements Folder > icon Folder > CSS Folder > icon.ts */
22
-
23
- /* WebComponent 1: logged-in
24
- <user-icon>
25
- <button class="icon"> */
26
- --pwa_icon_diameter: 32px; /* sync to --pwa_icon_height */ /* custom-elements Folder > icon Folder > CSS Folder > icon.ts */
27
-
28
- }
29
-
30
- `;
31
- export const drawerRoot = css `
32
-
33
- /* CSS: Custom Variables: <head> tag */
34
-
35
- :root {
36
-
37
- /* WebComponent 2: Drop-down Drawer
38
- <user-drawer>
39
- <section>
40
- <header></header>
41
- <div class="spec"> */
42
- --pwa_drawer_border: 3px #303030 solid; /* custom-elements Folder > drawer Folder > CSS Folder > drawer.ts */
43
- --pwa_drawer_z-index: 2; /* custom-elements Folder > drawer Folder > CSS Folder > drawer.ts */
44
- --pwa_drawer_border-radius: 20px; /* custom-elements Folder > drawer Folder > CSS Folder > drawer.ts */
45
-
46
- /* WebComponent 2: Drop-down Drawer - logged-out
47
- <div class="spec"> */
48
- --pwa_drawer_text_color: #303030; /* custom-elements Folder > drawer Folder > CSS Folder > drawer.ts */
49
- --pwa_drawer_background_color: #fff; /* custom-elements Folder > drawer Folder > CSS Folder > drawer.ts */
50
-
51
- /* WebComponent 2: Drop-down Drawer - logged-in
52
- <div class="spec" on> */
53
-
54
- }
55
-
56
- `;
57
- export const settingsRoot = css `
58
-
59
- /* CSS: Custom Variables: <head> tag */
60
-
61
- :root {
62
-
63
- /* WebComponent 3: Settings Page
64
- <user-settings>
65
- <nav></nav>
66
- <section></section> */
67
- --pwa_settings_background: white; /* custom-elements Folder > settings Folder > settings.ts */
68
- --pwa_divider: black; /* custom-elements Folder > settings Folder > settings.ts */
69
-
70
- /* Navigation */
71
- --pwa_nav_button: grey; /* custom-elements Folder > settings Folder > CSS Folder > navigation.ts */
72
- --pwa_nav_select: black; /* custom-elements Folder > settings Folder > CSS Folder > navigation.ts */
73
-
74
- /* Section Header */
75
- --pwa_section_header: black; /* custom-elements Folder > settings Folder > settings.ts */
76
-
77
- /* Label */
78
- --pwa_label_text_color: black; /* Form Folder > label.ts */
79
-
80
- /* Input */
81
- --pwa_input_background: #E1E5EB; /* Form Folder > input.ts */
82
-
83
- /* Button */
84
- --pwa_action_text_color: #fff; /* Form Folder > button.ts */
85
- --pwa_action_background_color: #6cc04a; /* Form Folder > button.ts */
86
- --pwa_action_border_color: #60b23e; /* Form Folder > button.ts */
87
-
88
- }
89
-
90
- `;
91
- export const themeRoot = css `
92
-
93
- /* Dark Theme */
94
- @media (prefers-color-scheme: dark) { }
95
-
96
- /* Light Theme */
97
- @media (prefers-color-scheme: light) { }
98
-
99
- `;
@@ -1,2 +0,0 @@
1
- export declare const fontStyles: import("lit").CSSResult;
2
- //# sourceMappingURL=font.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"font.d.ts","sourceRoot":"","sources":["../../source/css/font.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,UAAU,yBActB,CAAC"}
@@ -1,16 +0,0 @@
1
- import { css } from "lit";
2
- export const fontStyles = css `
3
-
4
- /* */
5
- .x-font {
6
- font-family: Roboto, Arial, sans-serif; /* 'Montserrat' */
7
- line-height: 1.1;
8
- letter-spacing: .007em;
9
- font-size: 14px;
10
- font-weight: 500;
11
- text-align: center;
12
- text-decoration-style: solid;
13
- text-transform: uppercase;
14
- }
15
-
16
- `;
@@ -1,3 +0,0 @@
1
- import { CSSResult } from "lit";
2
- export declare const buttonStyle: CSSResult;
3
- //# sourceMappingURL=button.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../../source/css/form/button.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAA;AAEpC,eAAO,MAAM,WAAW,EAAE,SAoDzB,CAAC"}
@@ -1,54 +0,0 @@
1
- import { css } from "lit";
2
- export const buttonStyle = css `
3
-
4
- .action-button:focus { outline:0; }
5
-
6
- .action-button {
7
- display: inline-block;
8
- box-sizing: border-box;
9
- white-space: nowrap;
10
- margin: 16px 16px 16px auto;
11
- font-weight: 400;
12
- text-align: center;
13
- vertical-align: middle;
14
- touch-action: manipulation;
15
- -webkit-appearance: button;
16
- cursor: pointer;
17
- font-size: 16px;
18
- height: 38px;
19
- line-height: 16px;
20
- padding: 10px 16px;
21
- border-radius: 6px;
22
- color: var(--pwa_action_text_color, #fff);
23
- background-color: var(--pwa_action_background_color, #6cc04a);
24
- border-color: var(--pwa_action_border_color, #60b23e);
25
- box-shadow: 1px 1px 1px grey;
26
- }
27
-
28
- .saving{
29
- transition: background-color 0.3s; /* Smooth transition for hover effect */
30
- background-color: #D6EBD3;
31
- border: 0.5px solid black;
32
- border-radius: 4px;
33
- height: 50px;
34
- width: 100%;
35
- margin: auto;
36
- box-shadow: 1px 1px 1px grey;
37
- }
38
-
39
- /* */
40
- .submit:hover { background-color: #45a049; }
41
-
42
- .submit {
43
- box-sizing: border-box;
44
- width: 100%;
45
- background-color: #4CAF50;
46
- color: white;
47
- padding: 14px 20px;
48
- margin: 8px 0;
49
- border: none;
50
- border-radius: 4px;
51
- cursor: pointer;
52
- }
53
-
54
- `;
@@ -1,3 +0,0 @@
1
- import { CSSResult } from "lit";
2
- export declare const inputStyle: CSSResult;
3
- //# sourceMappingURL=input.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"input.d.ts","sourceRoot":"","sources":["../../../source/css/form/input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAC;AAErC,eAAO,MAAM,UAAU,EAAG,SAsBzB,CAAC"}
@@ -1,24 +0,0 @@
1
- import { css } from "lit";
2
- export const inputStyle = css `
3
-
4
- input[type=text],
5
- input[type=email],
6
- input[type=password],
7
- select {
8
- box-sizing: border-box;
9
- -webkit-box-sizing: border-box;
10
- height: 50px;
11
- text-align: left;
12
- margin: 0 16px 0 16px;
13
- padding: 8px 16px;
14
- background-color: var(--pwa_input_background, #E1E5EB);
15
- border: 0;
16
- border-radius: 4px;
17
- -webkit-border-radius: 4px;
18
- font-size: smaller;
19
- box-shadow: 1px 1px 1px grey;
20
- }
21
-
22
- input.invalid { background-color: #ffdddd; }
23
-
24
- `;
@@ -1,3 +0,0 @@
1
- import { CSSResult } from "lit";
2
- export declare const labelStyle: CSSResult;
3
- //# sourceMappingURL=label.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"label.d.ts","sourceRoot":"","sources":["../../../source/css/form/label.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAC;AAErC,eAAO,MAAM,UAAU,EAAG,SAoBzB,CAAC"}
@@ -1,22 +0,0 @@
1
- import { css } from "lit";
2
- export const labelStyle = css `
3
-
4
- label { font-size: .9em; }
5
- label {
6
- display: grid;
7
- color: var(--pwa_label_text_color, black);
8
- box-sizing: border-box;
9
- font-size: smaller;
10
- margin-bottom: 0;
11
- font-weight: bold;
12
- line-height: 36px;
13
- padding: 0 16px;
14
- }
15
-
16
- @media (max-width: 460px) {
17
-
18
- label { font-size: .8em; }
19
-
20
- }
21
-
22
- `;
@@ -1,3 +0,0 @@
1
- import { CSSResult } from "lit";
2
- export declare const listStyle: CSSResult;
3
- //# sourceMappingURL=list.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"list.d.ts","sourceRoot":"","sources":["../../../source/css/form/list.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,SAAS,EAAE,MAAM,KAAK,CAAC;AAErC,eAAO,MAAM,SAAS,EAAE,SAoBvB,CAAC"}