Skip to content

Commit

Permalink
chore: init build cli
Browse files Browse the repository at this point in the history
  • Loading branch information
wenqing committed Aug 14, 2023
1 parent 4d4fc79 commit 6a1e6f3
Show file tree
Hide file tree
Showing 26 changed files with 95 additions and 452 deletions.
2 changes: 1 addition & 1 deletion index.html
Expand Up @@ -4,7 +4,7 @@
<meta charset="UTF-8">
<link rel="icon" href="/favicon.ico">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Vite App</title>
<title>starscore example</title>
</head>
<body>
<div id="app"></div>
Expand Down
2 changes: 2 additions & 0 deletions lib/index.d.ts
@@ -0,0 +1,2 @@

export { }
8 changes: 7 additions & 1 deletion package.json
Expand Up @@ -15,7 +15,8 @@
"import": "./lib/starscore.js",
"require": "./lib/starscore.cjs",
"types": "./lib/index.d.ts"
}
},
"./lib/style.css": "./lib/style.css"
},
"keywords": [
"star",
Expand All @@ -25,6 +26,10 @@
"files": [
"lib"
],
"repository": {
"url": "https://github.com/vcjs-dev/starscore"
},
"homepage": "https://github.com/vcjs-dev/starscore",
"scripts": {
"dev": "vite",
"build": "run-p type-check build-only",
Expand Down Expand Up @@ -60,6 +65,7 @@
"prettier": "^3.0.0",
"rollup": "^3.28.0",
"rollup-plugin-dts": "^5.3.1",
"sass": "^1.65.1",
"typescript": "~5.1.6",
"vite": "^4.4.6",
"vitest": "^0.33.0",
Expand Down
36 changes: 27 additions & 9 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file added public/.nojekyll
Empty file.
84 changes: 3 additions & 81 deletions src/App.vue
@@ -1,85 +1,7 @@
<script setup lang="ts">
import { RouterLink, RouterView } from 'vue-router'
import HelloWorld from './components/HelloWorld.vue'
</script>

<template>
<header>
<img alt="Vue logo" class="logo" src="@/assets/logo.svg" width="125" height="125" />

<div class="wrapper">
<HelloWorld msg="You did it!" />

<nav>
<RouterLink to="/">Home</RouterLink>
<RouterLink to="/about">About</RouterLink>
</nav>
</div>
</header>

<RouterView />
</template>

<style scoped>
header {
line-height: 1.5;
max-height: 100vh;
}
.logo {
display: block;
margin: 0 auto 2rem;
}
nav {
width: 100%;
font-size: 12px;
text-align: center;
margin-top: 2rem;
}
nav a.router-link-exact-active {
color: var(--color-text);
}
nav a.router-link-exact-active:hover {
background-color: transparent;
}
nav a {
display: inline-block;
padding: 0 1rem;
border-left: 1px solid var(--color-border);
}
nav a:first-of-type {
border: 0;
}
@media (min-width: 1024px) {
header {
display: flex;
place-items: center;
padding-right: calc(var(--section-gap) / 2);
}
.logo {
margin: 0 2rem 0 0;
}
header .wrapper {
display: flex;
place-items: flex-start;
flex-wrap: wrap;
}
nav {
text-align: left;
margin-left: -1rem;
font-size: 1rem;
padding: 1rem 0;
margin-top: 1rem;
}
}
</style>
<script setup lang="ts">
import { RouterView } from 'vue-router'
</script>
22 changes: 2 additions & 20 deletions src/assets/base.css
Expand Up @@ -50,24 +50,6 @@
}
}

*,
*::before,
*::after {
box-sizing: border-box;
margin: 0;
font-weight: normal;
}

body {
min-height: 100vh;
color: var(--color-text);
background: var(--color-background);
transition: color 0.5s, background-color 0.5s;
line-height: 1.6;
font-family: Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu,
Cantarell, 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
font-size: 15px;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}


36 changes: 1 addition & 35 deletions src/assets/main.css
@@ -1,35 +1 @@
@import './base.css';

#app {
max-width: 1280px;
margin: 0 auto;
padding: 2rem;

font-weight: normal;
}

a,
.green {
text-decoration: none;
color: hsla(160, 100%, 37%, 1);
transition: 0.4s;
}

@media (hover: hover) {
a:hover {
background-color: hsla(160, 100%, 37%, 0.2);
}
}

@media (min-width: 1024px) {
body {
display: flex;
place-items: center;
}

#app {
display: grid;
grid-template-columns: 1fr 1fr;
padding: 0 2rem;
}
}
@import './base.css';
41 changes: 0 additions & 41 deletions src/components/HelloWorld.vue

This file was deleted.

0 comments on commit 6a1e6f3

Please sign in to comment.