diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json deleted file mode 100644 index 8d96444..0000000 --- a/.devcontainer/devcontainer.json +++ /dev/null @@ -1,26 +0,0 @@ -// For format details, see https://aka.ms/devcontainer.json. For config options, see the -// README at: https://github.com/devcontainers/templates/tree/main/src/docker-existing-dockerfile -{ - "name": "Existing Dockerfile", - "build": { - // Sets the run context to one level up instead of the .devcontainer folder. - "context": "..", - // Update the 'dockerFile' property if you aren't using the standard 'Dockerfile' filename. - "dockerfile": "../Dockerfile" - } - - // Features to add to the dev container. More info: https://containers.dev/features. - // "features": {}, - - // Use 'forwardPorts' to make a list of ports inside the container available locally. - // "forwardPorts": [], - - // Uncomment the next line to run commands after the container is created. - // "postCreateCommand": "cat /etc/os-release", - - // Configure tool-specific properties. - // "customizations": {}, - - // Uncomment to connect as an existing user other than the container default. More info: https://aka.ms/dev-containers-non-root. - // "remoteUser": "devcontainer" -} diff --git a/.drone.yml b/.drone.yml deleted file mode 100644 index 3ee435a..0000000 --- a/.drone.yml +++ /dev/null @@ -1,14 +0,0 @@ -pipeline: - build: - image: node:12.18.3 - commands: - - yarn - - yarn build - - deploy: - image: node:12.18.3 - commands: - - yarn deploy - secrets: [ aws_access_key_id, aws_secret_access_key ] - when: - branch: main diff --git a/.github/workflows/publish-npm.yml b/.github/workflows/publish-npm.yml new file mode 100644 index 0000000..0440e42 --- /dev/null +++ b/.github/workflows/publish-npm.yml @@ -0,0 +1,59 @@ +name: Build and publish + +on: + release: + types: [created] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: 25 + - run: npm --version + - run: npm ci + - run: npm run compile + + publish-npm: + needs: build + runs-on: ubuntu-latest + if: ${{ !github.event.skip_publish_npm }} + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: 25 + registry-url: https://registry.npmjs.org/ + - run: npm ci + - run: npm run compile + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{secrets.npm_token}} + + publish-s3: + needs: build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: 25 + registry-url: https://registry.npmjs.org/ + - run: npm ci + - run: npm run compile + - run: npm run prepare-s3-output + - name: get-npm-version + id: package-version + uses: martinbeentjes/npm-get-version-action@v1.3.1 + - uses: jakejarvis/s3-sync-action@master + with: + args: --acl public-read --follow-symlinks --delete + env: + AWS_S3_BUCKET: csh-material-bootstrap + AWS_ACCESS_KEY_ID: ${{secrets.S3_ACCESS_KEY}} + AWS_SECRET_ACCESS_KEY: ${{secrets.S3_SECRET_KEY}} + AWS_S3_ENDPOINT: https://s3.csh.rit.edu + SOURCE_DIR: s3-output + DEST_DIR: ${{steps.package-version.outputs.current-version}} diff --git a/.gitignore b/.gitignore index be2089d..c9a659f 100644 --- a/.gitignore +++ b/.gitignore @@ -102,6 +102,9 @@ typings/ # dotenv environment variables file .env +.secrets # JetBrains .idea + +s3-output diff --git a/.nvmrc b/.nvmrc deleted file mode 100644 index 9cd25a1..0000000 --- a/.nvmrc +++ /dev/null @@ -1 +0,0 @@ -12.18.3 diff --git a/Dockerfile b/Dockerfile deleted file mode 100644 index bc601d9..0000000 --- a/Dockerfile +++ /dev/null @@ -1,15 +0,0 @@ -FROM node:19 AS base -RUN touch ~/.bashrc && chmod +x ~/.bashrc -RUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash -RUN . ~/.nvm/nvm.sh -RUN . ~/.nvm/nvm.sh install 13 -RUN . ~/.nvm/nvm.sh use 13 -RUN apt update -RUN apt install -y python2 -WORKDIR /app -COPY package.json . -RUN yarn - -FROM base AS build -WORKDIR /app -COPY . . \ No newline at end of file diff --git a/README.md b/README.md index 15ae3ad..bf4d748 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,12 @@ CSH Material Bootstrap ======================= -A [Bootstrap](http://getbootstrap.com) material theme designed for use on [Computer Science House](http://csh.rit.edu) websites. Based on [Materia](https://bootswatch.com/materia) by [Bootswatch](https://bootswatch.com). +A [Bootstrap](http://getbootstrap.com) material theme designed for use on [Computer Science House](http://csh.rit.edu) websites. Demo ---- -A live demo of this theme that showcases most components can be found [here](https://s3.csh.rit.edu/csh-material-bootstrap/4.3.1/index.html). +A live demo of this theme that showcases most components can be found [here](https://s3.csh.rit.edu/csh-material-bootstrap/5.3.9/index.html). Usage ------ @@ -22,13 +22,15 @@ npm install --save csh-material-bootstrap You can then include the stylesheet into your bundled project: ``` -import 'csh-material-bootstrap/dist/csh-material-bootstrap.css'; +import 'csh-material-bootstrap/css'; ``` Or with SCSS: ``` -@import "node_modules/csh-material-bootstrap/src/csh-material-bootstrap.scss"; +@use 'pkg:csh-material-bootstrap'; +# or +@import 'csh-material-bootstrap'; # ??? idk I haven't tested this, use the @use one, @import is deprecated ``` #### CDN @@ -37,20 +39,23 @@ Use CSH Material Bootstrap without a package manager. ###### CSS ``` - + ``` -###### JS, Popper.js, and jQuery +###### JS ``` - - - + ``` +#### Themes +To use different themes and enable theme switching on your website, you must include `colors-modes.js`. See [the website](https://assets.csh.rit.edu/csh-material-bootstrap/5.3.9/index.html#theme-switchers) for more details + Development ------------ -You must have [Node 6 or higher](https://nodejs.org) and NPM or [Yarn](https://yarnpkg.com) installed. +You must have [Node](https://nodejs.org) and NPM installed. Once you have those tools installed, clone this repo and run the following command to install dependencies: @@ -58,14 +63,10 @@ Once you have those tools installed, clone this repo and run the following comma npm install ``` -Or, with Yarn: - -``` -yarn -``` - -Once all of the dependencies are installed, run `npm build` to build the stylesheet (artifacts will be dropped in `./dist`), or `npm start` to watch the source files for development. +Once all of the dependencies are installed, run `npm compile` to build the stylesheet (artifacts will be dropped in `./dist`). +If you wish to work on the docs, run `npm run dev-docs`, which will launch a websever with Vite on port 5173 to watch the changes. +NOTE: you have to recompile the styles any time you update that right now Contributing ------------- diff --git a/index.html b/index.html index 08bfb7e..a6373a3 100644 --- a/index.html +++ b/index.html @@ -1,1660 +1,315 @@ - - - CSH Material Bootstrap - - - - - - - - -