Skip to content

Commit

Permalink
branch learninhg - cumulative changes
Browse files Browse the repository at this point in the history
  • Loading branch information
santiagoaloi committed Aug 4, 2022
1 parent 4b2bf82 commit f878f4c
Show file tree
Hide file tree
Showing 40 changed files with 4,881 additions and 4,066 deletions.
2 changes: 1 addition & 1 deletion functions/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const functions = require('firebase-functions');
admin.initializeApp();

// Appcheck protected / reCAPTCHA authorices only skriptag.com domain.
exports.listAllUsers = functions.region('us-central1').https.onCall(async (data, context) => {
exports.listAllUsers = functions.https.onCall(async (data, context) => {
// If appCheck fails, terminate the funciton.
if (!context.app) {
throw new functions.https.HttpsError('failed-precondition', 'The function must be called from an App Check verified app.');
Expand Down
6,696 changes: 3,575 additions & 3,121 deletions package-lock.json

Large diffs are not rendered by default.

8 changes: 6 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@
"name": "skriptag",
"version": "0.1.0",
"private": true,
"author": "Santiago Aloi",
"author": {
"name": "Santiago Aloi",
"email": "santiago.aloi@skriptag.com"
},
"homepage": "https://skriptag.com",
"scripts": {
"serve": "vue-cli-service serve",
"build": "vue-cli-service build",
Expand All @@ -15,7 +19,7 @@
"firebase": "^9.8.2",
"localforage": "^1.10.0",
"vee-validate": "3.4.5",
"vue": "^2.6.11",
"vue": "^2.7.8",
"vue-burger": "^1.1.0",
"vue-router": "^3.5.4",
"vuesax": "^4.0.1-alpha.25",
Expand Down
File renamed without changes
16 changes: 14 additions & 2 deletions public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
<meta name="twitter:card" content="summary_large_image" />
<meta property="twitter:domain" content="skriptag.com" />
<meta property="twitter:url" content="https://skriptag.com/" />
<meta name="twitter:title" content="Skriptag Web development, resources and training." />
<meta name="twitter:title" content="Skriptag: Web development, resources and training." />
<meta
name="twitter:description"
content="I&#x27;m Santiago Aloi, a full-stack developer from Stockholm,Sweden. I design and develop websites, apps, and much more. I also teach others to code!"
Expand All @@ -35,8 +35,20 @@

<meta name="keywords" content="Skriptag>" />
<title>Skriptag — Web development, resources and training.</title>

<!-- Global site tag (gtag.js) - Google Analytics -->
<!-- <script async src="https://www.googletagmanager.com/gtag/js?id=G-K501S3ZMTW"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag() {
dataLayer.push(arguments);
}
gtag('js', new Date());
gtag('config', 'G-K501S3ZMTW');
</script> -->
</head>
<body>
<b id="app" />
<div id="app" />
</body>
</html>
58 changes: 33 additions & 25 deletions src/App.vue
Original file line number Diff line number Diff line change
@@ -1,40 +1,48 @@
<template>
<router-view />
<v-fade-transition appear>
<router-view />
</v-fade-transition>
</template>

<script>
import { get, call } from 'vuex-pathify';
import { isEmpty } from 'lodash';
// import { get, call } from 'vuex-pathify';
// import { isEmpty } from 'lodash';
export default {
name: 'BaseApp',
name: 'App',
computed: {
...get('authentication', ['isAccountDisabled', 'profile']),
// ...get('authentication', ['isAccountDisabled', 'profile']),
},
renderTracked({ key, target, type }) {
console.log('renderTracked:', { key, target, type });
},
renderTriggered({ key, target, type }) {
console.log('renderTriggered:', { key, target, type });
},
// The authenticated account profile gets real-time updates.
// If the disabled flag shows up, that means that auth is revoked.
// We are reacting to isAccountDisabled Vuex getter and forcing a logout.
watch: {
isAccountDisabled(disabled) {
if (disabled) {
this.logout();
this.snackbarError('You have been logged out, contact support.');
}
},
// watch: {
// isAccountDisabled(disabled) {
// if (disabled) {
// this.logout();
// this.snackbarError('You have been logged out, contact support.');
// }
// },
// If the authenticated account profile is missing
// force a logout.
profile(profile) {
if (isEmpty(profile)) {
this.logout();
}
},
},
// // If the authenticated account profile is missing
// // force a logout.
// // profile(profile) {
// // if (isEmpty(profile)) {
// // this.logout();
// // }
// // },
// },
methods: {
...call('snackbar', ['snackbarError']),
...call('authentication', ['logout']),
},
// methods: {
// ...call('snackbar', ['snackbarError']),
// ...call('authentication', ['logout']),
// },
};
</script>
23 changes: 21 additions & 2 deletions src/assets/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@
font-weight: normal;
src: local('Product Sans Black Italic'), url('ProductSans-BlackItalic.woff') format('woff');
}

.v-application,
h1:not(.ignore-font),
h2:not(.ignore-font),
h3,
Expand Down Expand Up @@ -135,7 +135,6 @@ a {
}
.v-application--wrap {
background: #22272e !important;
height: 0vh !important;
}

.bgs {
Expand Down Expand Up @@ -249,6 +248,26 @@ html {
box-shadow: inset 0 0 0 20px transparent;
}

.testing:focus {
background-color: red;
}
.v-input__slot {
transition: unset !important;
}

/* .v-input.v-text-field {
transition: all 0.65s ease !important;
} */

.v-input.v-text-field > .v-input__control > .v-input__slot {
transition: all 0.65s ease !important;
}

.v-input.v-text-field:focus-within > .v-input__control > .v-input__slot {
outline: 2px solid #5c77a5 !important;
background: #1e2227 !important;
}

.vs-input__icon {
background: rgb(24, 31, 38);
margin-left: 3px;
Expand Down
14 changes: 14 additions & 0 deletions src/assets/scss/vuetify/variables/_global.scss
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,17 @@ $border-radius-root: 6px;
// $btn-font-weight: 700;
$btn-text-transform: none;
$btn-letter-spacing: normal;




// // Transitions
// $transition: (
// // "fast-out-linear-in": cubic-bezier(0.4, 0, 1, 1),
// // "fast-in-fast-out": cubic-bezier(0.25, 0.8, 0.25, 1),
// "fast-out-slow-in": unset,
// // "ease-in-out": cubic-bezier(0.4, 0, 0.6, 1),
// // "swing": cubic-bezier(0.25, 0.8, 0.5, 1),
// /* Sidebars */ "linear-out-slow-in": unset,
// /* Component card flicker problem "fast-out-slow-in": cubic-bezier(0.69, 0.39, 0.51, 0.49) */
// );
90 changes: 90 additions & 0 deletions src/components/base/BaseBackToTop.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
<template>
<transition name="fade">
<svg v-if="show" class="go-to-top" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 49.484 28.284" @click="scrollToTop">
<g transform="translate(-229 -126.358)">
<rect fill="currentColor" width="35" height="5" rx="2" transform="translate(229 151.107) rotate(-45)" />
<rect fill="currentColor" width="35" height="5" rx="2" transform="translate(274.949 154.642) rotate(-135)" />
</g>
</svg>
</transition>
</template>

<script>
import debounce from 'lodash.debounce';
export default {
name: 'BaseBackToTop',
props: {
threshold: {
type: Number,
default: 50,
},
},
data() {
return {
scrollTop: null,
};
},
computed: {
show() {
return this.scrollTop > this.threshold;
},
},
mounted() {
this.scrollTop = this.getScrollTop();
window.addEventListener(
'scroll',
debounce(() => {
this.scrollTop = this.getScrollTop();
}, 100),
);
},
methods: {
getScrollTop() {
return window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop || 0;
},
scrollToTop() {
window.scrollTo({ top: 0, behavior: 'smooth' });
this.scrollTop = 0;
},
},
};
</script>

<style lang="scss" scoped>
.go-to-top {
cursor: pointer;
position: fixed;
bottom: 2rem;
right: 2.5rem;
width: 2rem;
color: red;
z-index: 1;
}
.go-to-top:hover {
color: lighten(red, 30%);
}
@media (max-width: 959px) {
.go-to-top {
display: none;
}
}
.fade-enter-active,
.fade-leave-active {
transition: opacity 0.3s;
}
.fade-enter,
.fade-leave-to {
opacity: 0;
}
</style>
Loading

0 comments on commit f878f4c

Please sign in to comment.