diff --git a/.eslintrc.js b/.eslintrc.js index c2607a8..13e63bd 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -6,7 +6,7 @@ module.exports = { }, extends: [ '@nuxtjs/eslint-config-typescript', - 'plugin:nuxt/recommended' + 'plugins:nuxt/recommended' ], plugins: [ ], diff --git a/.github/workflows/chrome-e2e.yaml b/.github/workflows/chrome-e2e.yaml new file mode 100644 index 0000000..82cb5f7 --- /dev/null +++ b/.github/workflows/chrome-e2e.yaml @@ -0,0 +1,68 @@ +name: Chrome E2E CI +on: + push: + branches: + - master + pull_request: + branches: + - master + +jobs: + test: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + containers: [ 1, 2, 3 ] + name: E2E on Chrome + steps: + - name: Checking out code ⚡ + uses: actions/checkout@v2 + + - name: Setting up NodeJS 📐 + uses: actions/setup-node@v1 + with: + node-version: '14.x' + + - name: Caching Dependencies 💾 + uses: actions/cache@v1 + with: + path: ~/.npm + key: ${{ runner.os }}-node-${{ hashFiles('**/yarn-lock.json') }} + restore-keys: | + ${{ runner.os }}-node- + + - name: Building 🏗 + run: | + npm install -g yarn + yarn install --frozen-lockfile + yarn install + + + - name: E2E Testing 🤖 + uses: cypress-io/github-action@v2 + env: + CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + record: true + start: yarn run dev + parallel: true + browser: chrome + wait-on-timeout: 120 + wait-on: 'http://localhost:3000' + + + - name: Uploading Screenshots ☁ + uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: cypress/screenshots + + - name: Uploading Videos ☁ + uses: actions/upload-artifact@v1 + if: always() + with: + name: cypress-videos + path: cypress/videos diff --git a/.github/workflows/netlify-deploy.yaml b/.github/workflows/netlify-deploy.yaml new file mode 100644 index 0000000..a2714c9 --- /dev/null +++ b/.github/workflows/netlify-deploy.yaml @@ -0,0 +1,27 @@ +name: Deploy +on: + push: + branches: + - master +jobs: + test: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + containers: [ 1, 2, 3 ] + name: Deploy + steps: + - name: Deploy to Netlify ✅ + uses: nwtgck/actions-netlify@v1.1 + with: + publish-dir: './dist' + production-branch: master + github-token: ${{ secrets.GITHUB_TOKEN }} + deploy-message: "Deploy from GitHub Actions" + enable-pull-request-comment: false + enable-commit-comment: true + overwrites-pull-request-comment: true + env: + NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }} + NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }} diff --git a/.gitignore b/.gitignore index e8f682b..07dfddd 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,4 @@ -# Created by .ignore support plugin (hsz.mobi) +# Created by .ignore support plugins (hsz.mobi) ### Node template # Logs /logs @@ -88,3 +88,5 @@ sw.* # Vim swap files *.swp + +cypress/ diff --git a/assets/css/tailwind.css b/assets/css/tailwind.css index c958a33..14ea76a 100644 --- a/assets/css/tailwind.css +++ b/assets/css/tailwind.css @@ -21,7 +21,7 @@ } .sub-heading { - @apply font-medium text-center text-base md:text-xl text-center text-gray-300 + @apply font-medium text-center text-base md:text-lg text-center text-gray-400 } .input { diff --git a/assets/images/background/final_edited.svg b/assets/images/background/final_edited.svg new file mode 100644 index 0000000..8f70fdf --- /dev/null +++ b/assets/images/background/final_edited.svg @@ -0,0 +1,1356 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/components/Global/Footer.vue b/components/Global/Footer.vue index cac97fa..b2a64d5 100644 --- a/components/Global/Footer.vue +++ b/components/Global/Footer.vue @@ -78,11 +78,11 @@

Policies

@@ -95,28 +95,40 @@ > Products

Know us

@@ -130,9 +142,11 @@

Andronix App

©2021 Andronix | Techriz. All Rights Reserved.

- Made with Tailwind, NuxtJS and NodeJS by Tailwind, NuxtJS by imprakharshukla in 🇮🇳

diff --git a/components/Global/Heading.vue b/components/Global/Heading.vue index 7944579..d727924 100644 --- a/components/Global/Heading.vue +++ b/components/Global/Heading.vue @@ -1,6 +1,6 @@ @@ -16,7 +16,7 @@ export default { this.observeAuthStateChange() }, methods: { - observeAuthStateChange: function () { + observeAuthStateChange () { let ctx = this auth.onAuthStateChanged(function (user) { if (user) { diff --git a/layouts/error.vue b/layouts/error.vue new file mode 100644 index 0000000..f6ef5d0 --- /dev/null +++ b/layouts/error.vue @@ -0,0 +1,34 @@ + + + + + diff --git a/lib/checkout/checkoutHelper.js b/lib/checkout/checkoutHelper.js index 8a8d8be..c8b190f 100644 --- a/lib/checkout/checkoutHelper.js +++ b/lib/checkout/checkoutHelper.js @@ -2,7 +2,7 @@ import axios from 'axios' const fetchPricing = async (productId, axios) => { try { - return await axios.get(`/gen/pricing?product_id=${productId}`) + return await axios.get(`/gen/pricing/?product_id=${productId}`) } catch (e) { console.log(e) } @@ -33,6 +33,7 @@ export const getPrices = async (productId, axios) => { } export const generateOrderId = async (data, axios) => { + console.log({ data }) try { const result = await axios.get('/rzp/generate', { params: data diff --git a/netlify.toml b/netlify.toml new file mode 100644 index 0000000..e69de29 diff --git a/nuxt.config.js b/nuxt.config.js index 8eabd82..fd6c740 100644 --- a/nuxt.config.js +++ b/nuxt.config.js @@ -1,4 +1,7 @@ export default { + generate: { + fallback: true + }, vue: { config: { silent: true @@ -12,7 +15,7 @@ export default { scr: 'https://checkout.razorpay.com/v1/checkout.js' } ], - title: 'andronix-website', + title: 'Andronix App', meta: [ { charset: 'utf-8' }, { @@ -46,18 +49,10 @@ export default { src: '~/plugins/animxyz.js', mode: 'client' }, - { - src: '~/plugins/anime.js', - mode: 'client' - }, { src: '~/plugins/viewer.js', }, '~/plugins/firebase.js', - { - src: '~/plugins/hamburger.js', - mode: 'client' - }, ], // Auto import components (https://go.nuxtjs.dev/config-components) @@ -73,6 +68,31 @@ export default { // Modules (https://go.nuxtjs.dev/config-modules) modules: [ + [ + 'nuxt-social-meta', + { + url: 'https://next.andronix.app', + title: 'Andronix App', + site_name: 'Andronix App', + description: 'Install Linux distributions like Ubuntu, Debian, Manjaro and more on your un-rooted Android device.', + img: 'Link to image in static folder', + locale: 'en_US', + twitter: '@AndronixApp', + twitter_card: 'summary_large_image', + themeColor: '#FF8B25', + }, + ], + ['@nuxtjs/robots', { + UserAgent: '*', + Disallow: '/user' + }], + /* ['@nuxtjs/sitemap', { + hostname: 'https://', + gzip: true, + exclude: [ + '/user/!**', + ] + }],*/ 'vue-scrollto/nuxt', // https://go.nuxtjs.dev/axios '@nuxtjs/axios', @@ -90,4 +110,10 @@ export default { // Build Configuration (https://go.nuxtjs.dev/config-build) build: {}, + + publicRuntimeConfig: {}, + privateRuntimeConfig: { + testAccountEmail: process.env.TEST_ACCOUNT_EMAIL, + testAccountPassword: process.env.TEST_ACCOUNT_PASSWORD + } } diff --git a/package.json b/package.json index fa02635..0680ca5 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,9 @@ "start": "nuxt-ts start", "generate": "nuxt-ts generate", "lint:js": "eslint --ext .js,.vue --ignore-path .gitignore .", - "lint": "yarn run lint:js" + "lint": "yarn run lint:js", + "e2e": "cypress run --browser chrome", + "e2e:open": "cypress open" }, "dependencies": { "@animxyz/core": "^0.4.0", @@ -18,21 +20,21 @@ "@nuxtjs/axios": "^5.13.0", "@nuxtjs/firebase": "^7.3.0", "@nuxtjs/recaptcha": "^0.6.2", + "@nuxtjs/robots": "^2.4.2", + "@nuxtjs/sitemap": "^2.4.0", "@tailwindcss/line-clamp": "^0.2.0", + "@tailwindcss/typography": "^0.4.0", "autoprefixer": "^9.8.6", "axios": "^0.21.1", "core-js": "^3.6.5", "firebase": "^8.2.1", "nuxt": "^2.14.12", - "overlayscrollbars-vue": "^0.2.2", + "nuxt-social-meta": "^0.0.5", "postcss": "^7.0.35", "tailwindcss": "npm:@tailwindcss/postcss7-compat@^2.0.2", "v-viewer": "^1.5.1", - "vue-animejs": "^2.1.1", - "vue-burger": "^1.1.0", "vue-loading-overlay": "^3.4.2", "vue-scrollto": "^2.20.0", - "vue-tasty-burgers": "1.1.8", "vue-tippy": "^4.7.2", "vue-toast-notification": "^0.6.0" }, @@ -43,7 +45,10 @@ "@nuxtjs/eslint-config-typescript": "^3.0.0", "@nuxtjs/eslint-module": "^2.0.0", "@nuxtjs/tailwindcss": "^3.4.2", + "@types/jest": "^26.0.20", "babel-eslint": "^10.1.0", + "chance": "^1.1.7", + "cypress": "^6.4.0", "eslint": "^7.8.1", "eslint-plugin-nuxt": "^1.0.0" } diff --git a/pages/about.vue b/pages/about.vue index db94f80..3c376c4 100644 --- a/pages/about.vue +++ b/pages/about.vue @@ -1,101 +1,128 @@