feat: listed versioning for beta builds (#192)
This commit is contained in:
@@ -1 +0,0 @@
|
|||||||
MANIFEST_KEY=
|
|
||||||
13
@types/css-imports.d.ts
vendored
13
@types/css-imports.d.ts
vendored
@@ -1,13 +0,0 @@
|
|||||||
declare module '*.module.css' {
|
|
||||||
const classes: { [key: string]: string };
|
|
||||||
export default classes;
|
|
||||||
}
|
|
||||||
|
|
||||||
declare module '*.module.scss' {
|
|
||||||
const classes: { [key: string]: string };
|
|
||||||
export default classes;
|
|
||||||
}
|
|
||||||
declare module '*.mp3' {
|
|
||||||
const src: string;
|
|
||||||
export default src;
|
|
||||||
}
|
|
||||||
22
@types/environment.d.ts
vendored
22
@types/environment.d.ts
vendored
@@ -1,22 +0,0 @@
|
|||||||
declare global {
|
|
||||||
namespace NodeJS {
|
|
||||||
interface ProcessEnv {
|
|
||||||
NODE_ENV: 'development' | 'production';
|
|
||||||
CI?: string;
|
|
||||||
/** set this to make sure the extension id is the same for unpacked extensions
|
|
||||||
* @see https://developer.chrome.com/docs/apps/app_identity/#copy_key */
|
|
||||||
MANIFEST_KEY?: string;
|
|
||||||
/**
|
|
||||||
* The Node semantic versioning-compatible version of the extension. For preview-style releases, this variable
|
|
||||||
* converts versions like 1.0.0.100 to 1.0.0-beta.1.
|
|
||||||
*/
|
|
||||||
SEMANTIC_VERSION?: string;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
type Environment = typeof process.env.NODE_ENV;
|
|
||||||
}
|
|
||||||
|
|
||||||
// If this file has no import/export statements (i.e. is a script)
|
|
||||||
// convert it into a module by adding an empty export statement.
|
|
||||||
export {};
|
|
||||||
6
@types/svg-import.d.ts
vendored
6
@types/svg-import.d.ts
vendored
@@ -1,6 +0,0 @@
|
|||||||
declare module "*.svg" {
|
|
||||||
import { ReactElement, SVGProps } from "react";
|
|
||||||
|
|
||||||
const ReactComponent: (props: SVGProps<SVGElement>) => ReactElement;
|
|
||||||
export default ReactComponent;
|
|
||||||
}
|
|
||||||
10
@types/vite-env.d.ts
vendored
Normal file
10
@types/vite-env.d.ts
vendored
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
/// <reference types="vite/client" />
|
||||||
|
|
||||||
|
interface ImportMetaEnv {
|
||||||
|
readonly VITE_PACKAGE_VERSION: string;
|
||||||
|
readonly VITE_BETA_BUILD?: 'true';
|
||||||
|
}
|
||||||
|
|
||||||
|
interface ImportMeta {
|
||||||
|
readonly env: ImportMetaEnv;
|
||||||
|
}
|
||||||
@@ -1,10 +1,10 @@
|
|||||||
{
|
{
|
||||||
"name": "ut-registration-plus",
|
"name": "ut-registration-plus",
|
||||||
"displayName": "UT Registration Plus",
|
"displayName": "UT Registration Plus",
|
||||||
"version": "2.0.0-beta1",
|
"version": "2.0.0-beta2",
|
||||||
"description": "The UT Registration Plus extension is a Chrome extension that allows students to easily register for classes at The University of Texas at Austin.",
|
"description": "UT Registration Plus is a Chrome extension that allows students to easily register for classes.",
|
||||||
"private": true,
|
"private": true,
|
||||||
"homepage": "sriramhariharan.com",
|
"homepage": "https://github.com/Longhorn-Developers/UT-Registration-Plus",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite",
|
"dev": "vite",
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
import ExtensionRoot from '@views/components/common/ExtensionRoot/ExtensionRoot';
|
import ExtensionRoot from '@views/components/common/ExtensionRoot/ExtensionRoot';
|
||||||
|
import Link from '@views/components/common/Link';
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -7,7 +8,28 @@ import React from 'react';
|
|||||||
export default function App() {
|
export default function App() {
|
||||||
return (
|
return (
|
||||||
<ExtensionRoot>
|
<ExtensionRoot>
|
||||||
<div>hello how are you doing today.</div>
|
<div className='text-base'>
|
||||||
|
<div className='font-serif'>
|
||||||
|
<i>“Real powerusers modify the sourcecode instead of using settings”</i> - doprz
|
||||||
|
</div>
|
||||||
|
<div className='font-serif'>
|
||||||
|
<i>
|
||||||
|
“become hackerman, go to{' '}
|
||||||
|
<Link
|
||||||
|
href='https://github.com/Longhorn-Developers/UT-Registration-Plus'
|
||||||
|
className='link font-serif! italic!'
|
||||||
|
>
|
||||||
|
github
|
||||||
|
</Link>{' '}
|
||||||
|
yay”
|
||||||
|
</i>{' '}
|
||||||
|
- razboy20
|
||||||
|
</div>
|
||||||
|
<p className='mt-2.5 text-sm text-ut-gray'>
|
||||||
|
{import.meta.env.VITE_PACKAGE_VERSION} - {import.meta.env.MODE}{' '}
|
||||||
|
{import.meta.env.VITE_BETA_BUILD ? 'beta' : ''}
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
</ExtensionRoot>
|
</ExtensionRoot>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,10 +17,10 @@ export default function CalendarFooter(): JSX.Element {
|
|||||||
<Link className='linkanimate' href='#'>
|
<Link className='linkanimate' href='#'>
|
||||||
<InstagramIcon className='h-6 w-6' />
|
<InstagramIcon className='h-6 w-6' />
|
||||||
</Link>
|
</Link>
|
||||||
<Link className='linkanimate' href='#'>
|
<Link className='linkanimate' href='https://discord.gg/bVh9g6VFwB'>
|
||||||
<DiscordIcon className='h-6 w-6' />
|
<DiscordIcon className='h-6 w-6' />
|
||||||
</Link>
|
</Link>
|
||||||
<Link className='linkanimate' href='#'>
|
<Link className='linkanimate' href='https://github.com/Longhorn-Developers/UT-Registration-Plus'>
|
||||||
<GithubIcon className='h-6 w-6' />
|
<GithubIcon className='h-6 w-6' />
|
||||||
</Link>
|
</Link>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ const links: LinkItem[] = [
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
text: 'Become a Beta Tester',
|
text: 'Become a Beta Tester',
|
||||||
url: '#',
|
url: 'https://discord.gg/bVh9g6VFwB',
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@@ -30,7 +30,12 @@ export function SmallLogo({ className }: { className?: string }): JSX.Element {
|
|||||||
<LogoIcon />
|
<LogoIcon />
|
||||||
<div className='flex flex-col text-lg font-medium leading-[1em]'>
|
<div className='flex flex-col text-lg font-medium leading-[1em]'>
|
||||||
<p className='text-nowrap text-ut-burntorange'>UT Registration</p>
|
<p className='text-nowrap text-ut-burntorange'>UT Registration</p>
|
||||||
<p className='text-ut-orange'>Plus</p>
|
<p className='text-ut-orange'>
|
||||||
|
Plus{' '}
|
||||||
|
<span className='text-xs'>
|
||||||
|
{import.meta.env.VITE_BETA_BUILD ? `(${import.meta.env.VITE_PACKAGE_VERSION})` : ''}
|
||||||
|
</span>
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
@@ -48,7 +53,12 @@ export function LargeLogo({ className }: { className?: string }): JSX.Element {
|
|||||||
<LogoIcon className='h-12 w-12' />
|
<LogoIcon className='h-12 w-12' />
|
||||||
<div className='hidden flex-col text-[1.35rem] font-medium leading-[1em] md:flex screenshot:flex'>
|
<div className='hidden flex-col text-[1.35rem] font-medium leading-[1em] md:flex screenshot:flex'>
|
||||||
<p className='text-nowrap text-ut-burntorange'>UT Registration</p>
|
<p className='text-nowrap text-ut-burntorange'>UT Registration</p>
|
||||||
<p className='text-ut-orange'>Plus</p>
|
<p className='text-ut-orange'>
|
||||||
|
Plus{' '}
|
||||||
|
<span className='text-sm'>
|
||||||
|
{import.meta.env.VITE_BETA_BUILD ? `(${import.meta.env.VITE_PACKAGE_VERSION})` : ''}
|
||||||
|
</span>
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -6,7 +6,10 @@
|
|||||||
"module": "esnext",
|
"module": "esnext",
|
||||||
"noEmit": true,
|
"noEmit": true,
|
||||||
"jsx": "react",
|
"jsx": "react",
|
||||||
"typeRoots": ["./node_modules/@types", "./@types/"],
|
"typeRoots": [
|
||||||
|
"./node_modules/@types",
|
||||||
|
"@types"
|
||||||
|
],
|
||||||
"skipLibCheck": true,
|
"skipLibCheck": true,
|
||||||
"esModuleInterop": true,
|
"esModuleInterop": true,
|
||||||
"resolveJsonModule": true,
|
"resolveJsonModule": true,
|
||||||
@@ -32,6 +35,7 @@
|
|||||||
"src",
|
"src",
|
||||||
"utils",
|
"utils",
|
||||||
"vite.config.ts",
|
"vite.config.ts",
|
||||||
|
"@types",
|
||||||
"node_modules/@types",
|
"node_modules/@types",
|
||||||
"src/manifest.ts",
|
"src/manifest.ts",
|
||||||
"package.json",
|
"package.json",
|
||||||
@@ -39,5 +43,7 @@
|
|||||||
"postcss.config.cjs",
|
"postcss.config.cjs",
|
||||||
".storybook",
|
".storybook",
|
||||||
"unocss.config.ts"
|
"unocss.config.ts"
|
||||||
|
,
|
||||||
|
"@types"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,15 +8,19 @@ import type { Plugin, ResolvedConfig, Rollup, ViteDevServer } from 'vite';
|
|||||||
import { defineConfig } from 'vite';
|
import { defineConfig } from 'vite';
|
||||||
import inspect from 'vite-plugin-inspect';
|
import inspect from 'vite-plugin-inspect';
|
||||||
|
|
||||||
|
import packageJson from './package.json';
|
||||||
import manifest from './src/manifest';
|
import manifest from './src/manifest';
|
||||||
|
|
||||||
const root = resolve(__dirname, 'src');
|
const root = resolve(__dirname, 'src');
|
||||||
const pagesDir = resolve(root, 'pages');
|
const pagesDir = resolve(root, 'pages');
|
||||||
const assetsDir = resolve(root, 'assets');
|
const assetsDir = resolve(root, 'assets');
|
||||||
const outDir = resolve(__dirname, 'dist');
|
|
||||||
const publicDir = resolve(__dirname, 'public');
|
const publicDir = resolve(__dirname, 'public');
|
||||||
|
|
||||||
const isDev = process.env.NODE_ENV === 'development';
|
const isBeta = !!process.env.BETA;
|
||||||
|
if (isBeta) {
|
||||||
|
process.env.VITE_BETA_BUILD = 'true';
|
||||||
|
}
|
||||||
|
process.env.VITE_PACKAGE_VERSION = packageJson.version;
|
||||||
|
|
||||||
export const preambleCode = `
|
export const preambleCode = `
|
||||||
import RefreshRuntime from "__BASE__@react-refresh"
|
import RefreshRuntime from "__BASE__@react-refresh"
|
||||||
|
|||||||
Reference in New Issue
Block a user