mirror of
https://github.com/nestriness/nestri.git
synced 2025-12-12 08:45:38 +02:00
✨ feat: Add www to cloudflare pages (#105)
Co-authored-by: --global <--global> Add our website to cloudflare pages
This commit is contained in:
60
.github/workflows/sst.yml
vendored
Normal file
60
.github/workflows/sst.yml
vendored
Normal file
@@ -0,0 +1,60 @@
|
|||||||
|
name: sst
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.ref }}
|
||||||
|
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
permissions:
|
||||||
|
id-token: write
|
||||||
|
contents: read
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
.sst
|
||||||
|
key: ${{ runner.os }}-sst
|
||||||
|
|
||||||
|
- uses: oven-sh/setup-bun@v1
|
||||||
|
with:
|
||||||
|
bun-version: latest
|
||||||
|
|
||||||
|
- uses: actions/setup-node@v1
|
||||||
|
with:
|
||||||
|
node-version: "20"
|
||||||
|
|
||||||
|
- run: "curl -fsSL https://ion.sst.dev/install | bash"
|
||||||
|
|
||||||
|
- if: github.ref == 'refs/heads/dev'
|
||||||
|
name: Configure Dev AWS credentials
|
||||||
|
uses: aws-actions/configure-aws-credentials@v1
|
||||||
|
with:
|
||||||
|
role-to-assume: arn:aws:iam::058264103289:role/terminal-shop-dev-github
|
||||||
|
aws-region: us-east-2
|
||||||
|
|
||||||
|
- if: github.ref == 'refs/heads/production'
|
||||||
|
name: Configure Production AWS credentials
|
||||||
|
uses: aws-actions/configure-aws-credentials@v1
|
||||||
|
with:
|
||||||
|
role-to-assume: arn:aws:iam::211125775473:role/terminal-shop-production-github
|
||||||
|
aws-region: us-east-2
|
||||||
|
|
||||||
|
- name: deps
|
||||||
|
run: bun install
|
||||||
|
|
||||||
|
- name: Deploy
|
||||||
|
env:
|
||||||
|
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
|
||||||
|
run: |
|
||||||
|
sst install
|
||||||
|
sst deploy --stage=${GITHUB_REF_NAME}
|
||||||
6
.gitignore
vendored
6
.gitignore
vendored
@@ -36,3 +36,9 @@ yarn-error.log*
|
|||||||
# Misc
|
# Misc
|
||||||
.DS_Store
|
.DS_Store
|
||||||
*.pem
|
*.pem
|
||||||
|
|
||||||
|
# sst
|
||||||
|
.sst
|
||||||
|
|
||||||
|
#Bun merging errors, EVERY time :(
|
||||||
|
bun.lockb
|
||||||
@@ -31,9 +31,9 @@
|
|||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@builder.io/qwik": "^1.8.0",
|
"@builder.io/qwik": "^1.8.0",
|
||||||
"@builder.io/qwik-city": "^1.8.0",
|
"@builder.io/qwik-city": "^1.8.0",
|
||||||
"@nestri/eslint-config": "workspace:*",
|
"@nestri/eslint-config": "*",
|
||||||
"@nestri/typescript-config": "workspace:*",
|
"@nestri/typescript-config": "*",
|
||||||
"@nestri/ui": "workspace:*",
|
"@nestri/ui": "*",
|
||||||
"@types/eslint": "8.56.10",
|
"@types/eslint": "8.56.10",
|
||||||
"@types/node": "20.14.11",
|
"@types/node": "20.14.11",
|
||||||
"@typescript-eslint/eslint-plugin": "7.16.1",
|
"@typescript-eslint/eslint-plugin": "7.16.1",
|
||||||
|
|||||||
@@ -16,7 +16,7 @@
|
|||||||
"@jsquash/avif": "^1.3.0",
|
"@jsquash/avif": "^1.3.0",
|
||||||
"@jsquash/jpeg": "^1.4.0",
|
"@jsquash/jpeg": "^1.4.0",
|
||||||
"@jsquash/resize": "^2.0.0",
|
"@jsquash/resize": "^2.0.0",
|
||||||
"@nestri/cache": "workspace:*",
|
"@nestri/cache": "*",
|
||||||
"tinycolor2": "^1.6.0",
|
"tinycolor2": "^1.6.0",
|
||||||
"wrangler": "^3.72.2"
|
"wrangler": "^3.72.2"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -32,9 +32,9 @@
|
|||||||
"@builder.io/qwik": "^1.8.0",
|
"@builder.io/qwik": "^1.8.0",
|
||||||
"@builder.io/qwik-city": "^1.8.0",
|
"@builder.io/qwik-city": "^1.8.0",
|
||||||
"@builder.io/qwik-react": "0.5.0",
|
"@builder.io/qwik-react": "0.5.0",
|
||||||
"@nestri/eslint-config": "workspace:*",
|
"@nestri/eslint-config": "*",
|
||||||
"@nestri/typescript-config": "workspace:*",
|
"@nestri/typescript-config": "*",
|
||||||
"@nestri/ui": "workspace:*",
|
"@nestri/ui": "*",
|
||||||
"@types/eslint": "8.56.10",
|
"@types/eslint": "8.56.10",
|
||||||
"@types/node": "^22.5.1",
|
"@types/node": "^22.5.1",
|
||||||
"@types/react": "^18.2.28",
|
"@types/react": "^18.2.28",
|
||||||
|
|||||||
@@ -1 +1,7 @@
|
|||||||
module.exports = require("@nestri/ui/postcss.config");
|
// module.exports = require("@nestri/ui/postcss.config");
|
||||||
|
module.exports = {
|
||||||
|
plugins: {
|
||||||
|
tailwindcss: {},
|
||||||
|
autoprefixer: {},
|
||||||
|
},
|
||||||
|
};
|
||||||
@@ -1,7 +1,5 @@
|
|||||||
import { component$ } from "@builder.io/qwik";
|
import { component$ } from "@builder.io/qwik";
|
||||||
import { Link } from "@builder.io/qwik-city";
|
import { Link } from "@builder.io/qwik-city";
|
||||||
import { buttonVariants, cn } from "@nestri/ui/design";
|
|
||||||
|
|
||||||
|
|
||||||
export default component$(() => {
|
export default component$(() => {
|
||||||
return (
|
return (
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
/* eslint-disable qwik/jsx-img */
|
||||||
import { component$ } from "@builder.io/qwik";
|
import { component$ } from "@builder.io/qwik";
|
||||||
import { Link } from "@builder.io/qwik-city";
|
import { Link } from "@builder.io/qwik-city";
|
||||||
import { NavBar, Footer } from "@nestri/ui";
|
import { NavBar, Footer } from "@nestri/ui";
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import { component$ } from "@builder.io/qwik";
|
import { component$ } from "@builder.io/qwik";
|
||||||
import { GameCard, HomeNavBar, Card } from "@nestri/ui";
|
import { HomeNavBar, Card } from "@nestri/ui";
|
||||||
|
|
||||||
function getGreeting(): string {
|
function getGreeting(): string {
|
||||||
const hour = new Date().getHours();
|
const hour = new Date().getHours();
|
||||||
|
|||||||
4
apps/www/sst-env.d.ts
vendored
Normal file
4
apps/www/sst-env.d.ts
vendored
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
/* tslint:disable */
|
||||||
|
/* eslint-disable */
|
||||||
|
/// <reference path="../../sst-env.d.ts" />
|
||||||
|
export {}
|
||||||
@@ -1,8 +1,8 @@
|
|||||||
// import colors from "tailwindcss/colors";
|
// import colors from "tailwindcss/colors";
|
||||||
import baseConfig from "@nestri/ui/tailwind.config";
|
import baseConfig from "@nestri/ui/tailwind.config";
|
||||||
/** @type {import('tailwindcss').Config} */
|
/** @type {import('tailwindcss').Config} */
|
||||||
module.exports = {
|
|
||||||
|
|
||||||
|
module.exports = {
|
||||||
content: [
|
content: [
|
||||||
"./{src,components,app}/**/*.{ts,tsx,html}",
|
"./{src,components,app}/**/*.{ts,tsx,html}",
|
||||||
"../../packages/ui/src/**/*.{ts,tsx}",
|
"../../packages/ui/src/**/*.{ts,tsx}",
|
||||||
|
|||||||
@@ -11,6 +11,7 @@
|
|||||||
"forceConsistentCasingInFileNames": true,
|
"forceConsistentCasingInFileNames": true,
|
||||||
"resolveJsonModule": true,
|
"resolveJsonModule": true,
|
||||||
"moduleResolution": "Bundler",
|
"moduleResolution": "Bundler",
|
||||||
|
"allowImportingTsExtensions": true,
|
||||||
"esModuleInterop": true,
|
"esModuleInterop": true,
|
||||||
"skipLibCheck": true,
|
"skipLibCheck": true,
|
||||||
"incremental": true,
|
"incremental": true,
|
||||||
@@ -24,7 +25,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"files": [
|
"files": [
|
||||||
".eslintrc.js"
|
".eslintrc.cjs"
|
||||||
],
|
],
|
||||||
"include": [
|
"include": [
|
||||||
"src",
|
"src",
|
||||||
|
|||||||
9
infra/domain.ts
Normal file
9
infra/domain.ts
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
export const domain =
|
||||||
|
{
|
||||||
|
production: "fst.so",
|
||||||
|
dev: "dev.fst.so",
|
||||||
|
}[$app.stage] || $app.stage + ".dev.fst.so";
|
||||||
|
|
||||||
|
export const zone = cloudflare.getZoneOutput({
|
||||||
|
name: "fst.so",
|
||||||
|
});
|
||||||
38
infra/github.ts
Normal file
38
infra/github.ts
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
import { isPermanentStage } from "./stage";
|
||||||
|
|
||||||
|
if (isPermanentStage) {
|
||||||
|
const github = new aws.iam.OpenIdConnectProvider("GithubProvider", {
|
||||||
|
url: "https://token.actions.githubusercontent.com",
|
||||||
|
clientIdLists: ["sts.amazonaws.com"],
|
||||||
|
thumbprintLists: [
|
||||||
|
"6938fd4d98bab03faadb97b34396831e3780aea1",
|
||||||
|
"1c58a3a8518e8759bf075b76b750d4f2df264fcd",
|
||||||
|
],
|
||||||
|
});
|
||||||
|
|
||||||
|
const githubRole = new aws.iam.Role("GithubRole", {
|
||||||
|
name: [$app.name, $app.stage, "github"].join("-"),
|
||||||
|
assumeRolePolicy: {
|
||||||
|
Version: "2012-10-17",
|
||||||
|
Statement: [
|
||||||
|
{
|
||||||
|
Effect: "Allow",
|
||||||
|
Principal: {
|
||||||
|
Federated: github.arn,
|
||||||
|
},
|
||||||
|
Action: "sts:AssumeRoleWithWebIdentity",
|
||||||
|
Condition: {
|
||||||
|
StringLike: github.url.apply((url) => ({
|
||||||
|
[`${url}:sub`]: "repo:nestriness/nestri:*",
|
||||||
|
})),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
|
new aws.iam.RolePolicyAttachment("GithubRolePolicy", {
|
||||||
|
policyArn: "arn:aws:iam::aws:policy/AdministratorAccess",
|
||||||
|
role: githubRole.name,
|
||||||
|
});
|
||||||
|
}
|
||||||
5
infra/secrets.ts
Normal file
5
infra/secrets.ts
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
export const secret = {
|
||||||
|
CloudflareAccountIdSecret: new sst.Secret("CloudflareAccountId"),
|
||||||
|
};
|
||||||
|
|
||||||
|
export const allSecrets = Object.values(secret);
|
||||||
2
infra/stage.ts
Normal file
2
infra/stage.ts
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
export const isPermanentStage =
|
||||||
|
$app.stage === "production" || $app.stage === "dev";
|
||||||
36
infra/www.ts
Normal file
36
infra/www.ts
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
//Deploys the website to cloudflare pages under the domain nestri.io (redirects all requests to www.nestri.io to avoid duplicate content)
|
||||||
|
// const cloudflareAccountId = new sst.Secret("CloudflareAccountId");
|
||||||
|
|
||||||
|
export const www = new cloudflare.PagesProject("www", {
|
||||||
|
name: "nestri",
|
||||||
|
accountId: "8405b2acb6746935b975bc2cfcb5c288",
|
||||||
|
productionBranch: "main",
|
||||||
|
buildConfig: {
|
||||||
|
rootDir: "apps/www",
|
||||||
|
// buildCommand: "bun run build",
|
||||||
|
destinationDir: "dist"
|
||||||
|
},
|
||||||
|
deploymentConfigs: {
|
||||||
|
production: {
|
||||||
|
compatibilityFlags: ["nodejs_compat"]
|
||||||
|
},
|
||||||
|
preview: {
|
||||||
|
compatibilityFlags: ["nodejs_compat"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
source: {
|
||||||
|
type: "github",
|
||||||
|
config: {
|
||||||
|
owner: "nestriness",
|
||||||
|
deploymentsEnabled: true,
|
||||||
|
productionBranch: "main",
|
||||||
|
repoName: "nestri",
|
||||||
|
productionDeploymentEnabled: true,
|
||||||
|
prCommentsEnabled: true,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
export const outputs = {
|
||||||
|
www: www.subdomain,
|
||||||
|
};
|
||||||
11
package.json
11
package.json
@@ -4,10 +4,12 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "turbo build",
|
"build": "turbo build",
|
||||||
"dev": "turbo dev",
|
"dev": "turbo dev",
|
||||||
"lint": "turbo lint",
|
"format": "prettier --write \"**/*.{ts,tsx,md}\"",
|
||||||
"format": "prettier --write \"**/*.{ts,tsx,md}\""
|
"lint": "turbo lint"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@cloudflare/workers-types": "4.20240821.1",
|
||||||
|
"@types/aws-lambda": "8.10.145",
|
||||||
"prettier": "^3.2.5",
|
"prettier": "^3.2.5",
|
||||||
"sst": "^3.0.91",
|
"sst": "^3.0.91",
|
||||||
"turbo": "^2.0.12",
|
"turbo": "^2.0.12",
|
||||||
@@ -25,5 +27,8 @@
|
|||||||
"core-js-pure",
|
"core-js-pure",
|
||||||
"esbuild",
|
"esbuild",
|
||||||
"workerd"
|
"workerd"
|
||||||
]
|
],
|
||||||
|
"dependencies": {
|
||||||
|
"sst": "3.0.94"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,9 +14,9 @@
|
|||||||
"@builder.io/qwik": "^1.8.0",
|
"@builder.io/qwik": "^1.8.0",
|
||||||
"@builder.io/qwik-city": "^1.8.0",
|
"@builder.io/qwik-city": "^1.8.0",
|
||||||
"@builder.io/qwik-react": "0.5.0",
|
"@builder.io/qwik-react": "0.5.0",
|
||||||
"@nestri/eslint-config": "workspace:*",
|
"@nestri/eslint-config": "*",
|
||||||
"@nestri/typescript-config": "workspace:*",
|
"@nestri/typescript-config": "*",
|
||||||
"@nestri/core": "workspace:*",
|
"@nestri/core": "*",
|
||||||
"@types/eslint": "^8.56.5",
|
"@types/eslint": "^8.56.5",
|
||||||
"@types/node": "^20.11.24",
|
"@types/node": "^20.11.24",
|
||||||
"autoprefixer": "^10.4.20",
|
"autoprefixer": "^10.4.20",
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"private": true,
|
"private": true,
|
||||||
"sideEffects": false,
|
"sideEffects": false,
|
||||||
"files": [
|
"files": [
|
||||||
"tailwind.config.ts",
|
"tailwind.config.js",
|
||||||
"postcss.config.js",
|
"postcss.config.js",
|
||||||
"globals.css"
|
"globals.css"
|
||||||
],
|
],
|
||||||
@@ -26,9 +26,9 @@
|
|||||||
"@builder.io/qwik-react": "0.5.0",
|
"@builder.io/qwik-react": "0.5.0",
|
||||||
"@fontsource/bricolage-grotesque": "^5.0.7",
|
"@fontsource/bricolage-grotesque": "^5.0.7",
|
||||||
"@fontsource/geist-sans": "^5.0.3",
|
"@fontsource/geist-sans": "^5.0.3",
|
||||||
"@nestri/eslint-config": "workspace:*",
|
"@nestri/eslint-config": "*",
|
||||||
"@nestri/typescript-config": "workspace:*",
|
"@nestri/typescript-config": "*",
|
||||||
"@nestri/core": "workspace:*",
|
"@nestri/core": "*",
|
||||||
"@turbo/gen": "^1.12.4",
|
"@turbo/gen": "^1.12.4",
|
||||||
"@types/eslint": "^8.56.5",
|
"@types/eslint": "^8.56.5",
|
||||||
"@types/node": "^20.11.24",
|
"@types/node": "^20.11.24",
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
export default {
|
module.exports = {
|
||||||
plugins: {
|
plugins: {
|
||||||
tailwindcss: {},
|
tailwindcss: {},
|
||||||
autoprefixer: {},
|
autoprefixer: {},
|
||||||
|
|||||||
@@ -10,7 +10,6 @@ type Props = {
|
|||||||
export const Card = component$(({ game }: Props) => {
|
export const Card = component$(({ game }: Props) => {
|
||||||
const imageUrl = `http://localhost:8787/image/cover/${game.id}.avif`
|
const imageUrl = `http://localhost:8787/image/cover/${game.id}.avif`
|
||||||
const backgroundColor = useSignal<string | undefined>(undefined);
|
const backgroundColor = useSignal<string | undefined>(undefined);
|
||||||
const ringColor = useSignal<string | undefined>(undefined);
|
|
||||||
const imgRef = useSignal<HTMLImageElement>();
|
const imgRef = useSignal<HTMLImageElement>();
|
||||||
|
|
||||||
const extractColor = $((img: HTMLImageElement) => {
|
const extractColor = $((img: HTMLImageElement) => {
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import { component$ } from "@builder.io/qwik";
|
import { component$ } from "@builder.io/qwik";
|
||||||
import { MotionComponent, transition } from "@/react/motion";
|
import { MotionComponent, transition } from "@nestri/ui/react";
|
||||||
import { Link } from "@builder.io/qwik-city";
|
import { Link } from "@builder.io/qwik-city";
|
||||||
|
|
||||||
export const GithubBanner = component$(() => {
|
export const GithubBanner = component$(() => {
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import { $, component$, useOnDocument, useSignal } from "@builder.io/qwik";
|
import { $, component$, useOnDocument, useSignal } from "@builder.io/qwik";
|
||||||
import { cn } from "@/design";
|
import { cn } from "./design";
|
||||||
|
|
||||||
export const HomeNavBar = component$(() => {
|
export const HomeNavBar = component$(() => {
|
||||||
const hasScrolled = useSignal(false);
|
const hasScrolled = useSignal(false);
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
/* eslint-disable qwik/no-use-visible-task */
|
/* eslint-disable qwik/no-use-visible-task */
|
||||||
import { cn } from '@/design';
|
import { cn } from '@nestri/ui/design';
|
||||||
import { component$, useSignal, useTask$, useStyles$, useVisibleTask$, $ } from '@builder.io/qwik';
|
import { component$, useSignal, useTask$, useStyles$, useVisibleTask$ } from '@builder.io/qwik';
|
||||||
|
|
||||||
interface ImageLoaderProps {
|
interface ImageLoaderProps {
|
||||||
src: string;
|
src: string;
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* eslint-disable qwik/no-use-visible-task */
|
/* eslint-disable qwik/no-use-visible-task */
|
||||||
import { cn } from '@/design';
|
import { cn } from '@nestri/ui/design';
|
||||||
import { component$, useSignal, useTask$, useStyles$, useVisibleTask$, $ } from '@builder.io/qwik';
|
import { component$, useSignal, useTask$, useStyles$, useVisibleTask$, $ } from '@builder.io/qwik';
|
||||||
|
|
||||||
interface ImageLoaderProps {
|
interface ImageLoaderProps {
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import {
|
|||||||
form,
|
form,
|
||||||
cn,
|
cn,
|
||||||
type InputProps as InputVariants,
|
type InputProps as InputVariants,
|
||||||
} from "@/design"
|
} from "./design"
|
||||||
import { type QwikIntrinsicElements, component$ } from '@builder.io/qwik';
|
import { type QwikIntrinsicElements, component$ } from '@builder.io/qwik';
|
||||||
|
|
||||||
export interface InputComponentProps extends Omit<QwikIntrinsicElements["input"], 'size'>, InputVariants {
|
export interface InputComponentProps extends Omit<QwikIntrinsicElements["input"], 'size'>, InputVariants {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { $, component$, useOnDocument, useSignal } from "@builder.io/qwik";
|
import { $, component$, useOnDocument, useSignal } from "@builder.io/qwik";
|
||||||
import { Link, useLocation } from "@builder.io/qwik-city";
|
import { Link, useLocation } from "@builder.io/qwik-city";
|
||||||
import { buttonVariants, cn } from "@/design";
|
import { buttonVariants, cn } from "./design";
|
||||||
|
|
||||||
const navLinks = [
|
const navLinks = [
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/** @jsxImportSource react */
|
/** @jsxImportSource react */
|
||||||
import React from 'react'
|
import React from 'react'
|
||||||
import { motion } from 'framer-motion'
|
import { motion } from 'framer-motion'
|
||||||
import { cn } from '@/design'
|
import { cn } from "@nestri/ui/design"
|
||||||
import { qwikify$ } from '@builder.io/qwik-react';
|
import { qwikify$ } from '@builder.io/qwik-react';
|
||||||
|
|
||||||
export const CursorSVG = ({ flip }: { flip?: boolean }) => (
|
export const CursorSVG = ({ flip }: { flip?: boolean }) => (
|
||||||
|
|||||||
@@ -6,9 +6,9 @@ import {
|
|||||||
type DisplayProps as DisplayVariants,
|
type DisplayProps as DisplayVariants,
|
||||||
type TextAlignProp,
|
type TextAlignProp,
|
||||||
type TextWeightProp
|
type TextWeightProp
|
||||||
} from "@/design"
|
} from "@nestri/ui/design"
|
||||||
import * as ReactBalancer from "react-wrap-balancer"
|
import * as ReactBalancer from "react-wrap-balancer"
|
||||||
import { cn } from "@/design"
|
import { cn } from "@nestri/ui/design"
|
||||||
import { qwikify$ } from "@builder.io/qwik-react"
|
import { qwikify$ } from "@builder.io/qwik-react"
|
||||||
|
|
||||||
type DisplaySize = DisplayVariants["size"]
|
type DisplaySize = DisplayVariants["size"]
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
/** @jsxImportSource react */
|
/** @jsxImportSource react */
|
||||||
import { qwikify$ } from "@builder.io/qwik-react";
|
import { qwikify$ } from "@builder.io/qwik-react";
|
||||||
import { motion } from "framer-motion"
|
import { motion } from "framer-motion"
|
||||||
import { ReactDisplay } from "@/react/display"
|
import { ReactDisplay } from "./display"
|
||||||
import * as React from "react"
|
import * as React from "react"
|
||||||
// type Props = {
|
// type Props = {
|
||||||
// children?: React.ReactElement[]
|
// children?: React.ReactElement[]
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { cn } from "@/design";
|
import { cn } from "@nestri/ui/design";
|
||||||
import { component$, useStore, type Component } from "@builder.io/qwik";
|
import { component$, useStore, type Component } from "@builder.io/qwik";
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
/** @jsxImportSource react */
|
/** @jsxImportSource react */
|
||||||
import React from 'react'
|
import React from 'react'
|
||||||
import { motion } from 'framer-motion'
|
import { cn } from "@nestri/ui/design"
|
||||||
import { cn } from '@/design'
|
|
||||||
import { qwikify$ } from '@builder.io/qwik-react';
|
import { qwikify$ } from '@builder.io/qwik-react';
|
||||||
|
|
||||||
export const CursorSVG = ({ flip }: { flip?: boolean }) => (
|
export const CursorSVG = ({ flip }: { flip?: boolean }) => (
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/** @jsxImportSource react */
|
/** @jsxImportSource react */
|
||||||
import { cn } from "@/design";
|
import { cn } from "@nestri/ui/design";
|
||||||
import { qwikify$ } from "@builder.io/qwik-react";
|
import { qwikify$ } from "@builder.io/qwik-react";
|
||||||
import React, { useEffect, useRef, useState } from "react";
|
import React, { useEffect, useRef, useState } from "react";
|
||||||
import {
|
import {
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import {
|
|||||||
type TextAlignProp,
|
type TextAlignProp,
|
||||||
type TextWeightProp,
|
type TextWeightProp,
|
||||||
cn
|
cn
|
||||||
} from "@/design"
|
} from "@nestri/ui/design"
|
||||||
// import * as ReactBalancer from "react-wrap-balancer"
|
// import * as ReactBalancer from "react-wrap-balancer"
|
||||||
import { qwikify$ } from "@builder.io/qwik-react"
|
import { qwikify$ } from "@builder.io/qwik-react"
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
/** @jsxImportSource react */
|
/** @jsxImportSource react */
|
||||||
import { qwikify$ } from "@builder.io/qwik-react";
|
import { qwikify$ } from "@builder.io/qwik-react";
|
||||||
import { motion } from "framer-motion"
|
import { motion } from "framer-motion"
|
||||||
import { ReactDisplay } from "@/react/display"
|
import { ReactDisplay } from "./display"
|
||||||
// type Props = {
|
// type Props = {
|
||||||
// children?: React.ReactElement[]
|
// children?: React.ReactElement[]
|
||||||
// }
|
// }
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import {
|
|||||||
type TextAlignProp,
|
type TextAlignProp,
|
||||||
type TextWeightProp,
|
type TextWeightProp,
|
||||||
cn
|
cn
|
||||||
} from "@/design"
|
} from "@nestri/ui/design"
|
||||||
import { qwikify$ } from "@builder.io/qwik-react";
|
import { qwikify$ } from "@builder.io/qwik-react";
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -3,10 +3,7 @@
|
|||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"outDir": "tmp",
|
"outDir": "tmp",
|
||||||
"rootDir": ".",
|
"rootDir": ".",
|
||||||
"allowImportingTsExtensions": true,
|
"allowImportingTsExtensions": true
|
||||||
"paths": {
|
|
||||||
"@/*": ["./src/*"]
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"files": [".eslintrc.js"],
|
"files": [".eslintrc.js"],
|
||||||
"include": ["src", "./*.d.ts"]
|
"include": ["src", "./*.d.ts"]
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
"extends": "@nestri/typescript-config/base.json",
|
"extends": "@nestri/typescript-config/base.json",
|
||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"outDir": "dist",
|
"outDir": "dist",
|
||||||
|
"allowImportingTsExtensions": true
|
||||||
},
|
},
|
||||||
"include": ["src", "./*.config.js","./.eslintrc.js"],
|
"include": ["src", "./*.config.js","./.eslintrc.js"],
|
||||||
"exclude": ["node_modules", "dist"]
|
"exclude": ["node_modules", "dist"]
|
||||||
|
|||||||
8
sst-env.d.ts
vendored
Normal file
8
sst-env.d.ts
vendored
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
/* tslint:disable */
|
||||||
|
/* eslint-disable */
|
||||||
|
import "sst"
|
||||||
|
declare module "sst" {
|
||||||
|
export interface Resource {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
export {}
|
||||||
20
sst.config.ts
Normal file
20
sst.config.ts
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
/// <reference path="./.sst/platform/config.d.ts" />
|
||||||
|
import { readdirSync } from "fs";
|
||||||
|
export default $config({
|
||||||
|
app(input) {
|
||||||
|
return {
|
||||||
|
name: "nestri",
|
||||||
|
removal: input?.stage === "production" ? "retain" : "remove",
|
||||||
|
home: "aws",
|
||||||
|
providers: { cloudflare: "5.37.1" },
|
||||||
|
};
|
||||||
|
},
|
||||||
|
async run() {
|
||||||
|
const outputs = {};
|
||||||
|
for (const value of readdirSync("./infra/")) {
|
||||||
|
const result = await import("./infra/" + value);
|
||||||
|
if (result.outputs) Object.assign(outputs, result.outputs);
|
||||||
|
}
|
||||||
|
return outputs;
|
||||||
|
},
|
||||||
|
});
|
||||||
1
tsconfig.json
Normal file
1
tsconfig.json
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{}
|
||||||
Reference in New Issue
Block a user