Skip to content

Commit

Permalink
Migrates docs from axdd-components repo.
Browse files Browse the repository at this point in the history
  • Loading branch information
charlon committed Jan 11, 2023
1 parent 870a419 commit 413231e
Show file tree
Hide file tree
Showing 60 changed files with 4,383 additions and 4 deletions.
Binary file added .DS_Store
Binary file not shown.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ build/Release
# Dependency directories
node_modules/
jspm_packages/
package-lock.json

# TypeScript v1 declaration files
typings/
Expand Down
28 changes: 28 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
FROM us-docker.pkg.dev/uwit-mci-axdd/containers/nginx-container:1.1.2 as pre-app-container

USER root

RUN apt-get update && apt-get install git -y

ADD docker/nginx.conf /etc/nginx/nginx.conf
RUN chgrp acait /etc/nginx/nginx.conf && chmod g+w /etc/nginx/nginx.conf


FROM us-docker.pkg.dev/uwit-mci-axdd/containers/nginx-container:1.1.2 AS node-bundler

USER acait

COPY --chown=acait:acait index.html package.json vite.config.js /app/
COPY --chown=acait:acait src /app/src
COPY --chown=acait:acait public /app/public

RUN . /app/bin/activate &&\
npm install --production &&\
npm install vite &&\
npm run build


FROM pre-app-container as app-container

USER acait
COPY --chown=acait:acait --from=node-bundler /app/dist /app/dist
5 changes: 3 additions & 2 deletions LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -178,15 +178,15 @@
APPENDIX: How to apply the Apache License to your work.

To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
boilerplate notice, with the fields enclosed by brackets "{}"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.

Copyright [yyyy] [name of copyright owner]
Copyright {yyyy} {name of copyright owner}

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand All @@ -199,3 +199,4 @@
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

60 changes: 58 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,58 @@
# solstice-docs
Solstice Design System documentation
[![Coverage Status](https://coveralls.io/repos/github/uw-it-aca/axdd-components/badge.svg?branch=main)](https://coveralls.io/github/uw-it-aca/axdd-components?branch=main)

# axdd-components
AXDD VueJS Component Library

* Vue 3
* Vite 2
* Bootstrap 5

## Recommended IDE Setup

[VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=johnsoncodehk.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=johnsoncodehk.vscode-typescript-vue-plugin).

## Customize configuration

See [Vite Configuration Reference](https://vitejs.dev/config/).

## Project Setup

```sh
npm install
```

### Compile and Hot-Reload for Development

```sh
npm run dev
```

### Compile and Build documentation website

```sh
npm run build
```

### Run Unit Tests with [Vitest](https://vitest.dev/)

```sh
npm run test:unit
```

### Run Unit Tests with Coverage report

```sh
npm run coverage
```

### Lint with [ESLint](https://eslint.org/)

```sh
npm run eslint
```

### Lint with [Stylelint](https://stylelint.io/)

```sh
npm run stylelint
```
13 changes: 13 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: '3.4'

services:
app:
environment:
PORT: 8000
restart: always
container_name: app-solstice-docs
build:
context: .
target: app-container
ports:
- "${RUNSERVER_PORT:-8000}:8000"
48 changes: 48 additions & 0 deletions docker/nginx.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# must run in foreground
daemon off;

worker_processes 1;
pid /var/run/nginx/nginx.pid;
error_log /dev/stderr;

events {
worker_connections 5000;
accept_mutex off; # set to 'on' if nginx worker_processes > 1
}

http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
sendfile on;
access_log /dev/stdout;

server {
listen ${PORT} default_server;
charset utf-8;
underscores_in_headers on;
port_in_redirect off;
root /app/dist;

location / {
try_files $uri $uri/ /index.html;
default_type text/html;
}

location = /favicon.ico {
return 204;
}

# include for app-specific location config
include /etc/nginx/includes/locations.conf;
}

server {
listen 8080;
server_name localhost;

location /basic_status {
stub_status on;
access_log off;
}
}
}
93 changes: 93 additions & 0 deletions docker/prod-values.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
autoscaling:
enabled: true
minReplicas: 1
maxReplicas: 2

ingress:
enabled: true
type: nginx
tls:
axdd-components:
secretName: components.axdd.s.uw.edu-ingress-cert
hosts:
- components.axdd.s.uw.edu
axdd-styleguide:
secretName: styleguide.axdd.s.uw.edu-ingress-cert
hosts:
- styleguide.axdd.s.uw.edu
hosts:
axdd-components:
host: components.axdd.s.uw.edu
paths:
- "/"
axdd-styleguide:
host: styleguide.axdd.s.uw.edu
paths:
- "/"
annotations:
cert-manager.io/cluster-issuer: letsencrypt
nginx.ingress.kubernetes.io/configuration-snippet: |
if ($host != 'components.axdd.s.uw.edu' ) {
return 301 $scheme://components.axdd.s.uw.edu;
}
repo: axdd-components
instance: prod

resources:
limits:
cpu: 500m
memory: 256Mi
requests:
cpu: 25m
memory: 128Mi

service:
enabled: true
ports:
- port: 80
targetPort: 8000
name: http
- port: 9113
targetPort: 9113
name: metrics

deploymentInitialization:
enabled: false

daemon:
enabled: false

database:
engine: null

externalService:
enabled: false

cronjob:
enabled: false

memcached:
enabled: false

certs:
mounted: false

gcsCredentials:
mounted: false

metrics:
enabled: true
serviceMonitor:
enabled: true
port: metrics

readiness:
enabled: false

lifecycle:
enabled: true

environmentVariables:
- name: "ENV"
value: "prod"
21 changes: 21 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<link rel="icon" href="/favicon.ico">
<title>AXDD Components</title>

<!-- google fonts -->
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Encode+Sans+Condensed:wght@400;500;700&family=Open+Sans:ital,wght@0,400;0,700;1,400&family=Roboto:wght@400;700&display=swap" rel="stylesheet">

</head>
<body>
<div id="app"></div>
<script type="module" src="/src/main.js"></script>
<!-- built files will be auto injected -->
</body>
</html>
45 changes: 45 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
{
"name": "axdd-components",
"scripts": {
"dev": "vite",
"build": "vite build",
"preview": "vite preview --port 5050",
"test:unit": "vitest",
"coverage": "vitest run --coverage",
"eslint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs --ignore-pattern '/dist/' --ignore-path .gitignore",
"stylelint": "stylelint '**/*.{vue,scss}'"
},
"dependencies": {
"@popperjs/core": "^2.11.6",
"@vueuse/core": "^9.10.0",
"axdd-components": "github:uw-it-aca/axdd-components#task/dark-mode",
"bootstrap": "^5.3.0-alpha1",
"bootstrap-icons": "^1.10.2",
"jquery": "^3.6.1",
"vue": "^3.2.45",
"vue-router": "^4.1.6",
"vue3-mq": "^3.1.3"
},
"devDependencies": {
"@rushstack/eslint-patch": "^1.2.0",
"@vitejs/plugin-vue": "^4.0.0",
"@vitest/coverage-c8": "^0.23.4",
"@vue/eslint-config-prettier": "^7.0.0",
"@vue/test-utils": "^2.2.4",
"eslint": "^8.28.0",
"eslint-plugin-vue": "^9.7.0",
"jsdom": "^20.0.3",
"postcss-html": "^1.5.0",
"prettier": "^2.8.0",
"prismjs": "^1.29.0",
"sass": "^1.56.1",
"stylelint": "^14.15.0",
"stylelint-config-prettier": "^9.0.4",
"stylelint-config-recommended-scss": "^7.0.0",
"stylelint-config-recommended-vue": "^1.4.0",
"stylelint-config-standard-scss": "^5.0.0",
"vite": "^4.0.0",
"vite-plugin-pages": "^0.28.0",
"vitest": "^0.23.4"
}
}
Binary file added public/favicon.ico
Binary file not shown.
10 changes: 10 additions & 0 deletions src/app.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<template>
<router-view></router-view>
</template>

<script>
export default {
name: "App",
components: {},
};
</script>
Loading

0 comments on commit 413231e

Please sign in to comment.