-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #42 from KSJaay/docs
Docs - Updates docs and fixes issues with demo mode
- Loading branch information
Showing
34 changed files
with
781 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<template> | ||
<div | ||
:style="{ backgroundColor: color.background, color: color.color }" | ||
class="badge" | ||
> | ||
<slot></slot> | ||
</div> | ||
</template> | ||
<script> | ||
export default { | ||
props: { | ||
color: { | ||
type: Object, | ||
default: { | ||
color: '#8f44e1', | ||
background: 'white', | ||
}, | ||
}, | ||
}, | ||
}; | ||
</script> | ||
|
||
<style scoped> | ||
.badge { | ||
padding: 3px 6px; | ||
display: inline-flex; | ||
align-items: center; | ||
border-radius: 8px; | ||
font-weight: 600; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
<!-- | ||
Type: Low, Medium, High, Bug, Design, Complete | ||
--> | ||
|
||
<template> | ||
<div id="app" class="kanban-container"> | ||
<div v-for="column in columns" :key="column.title" class="kanban-column"> | ||
<div class="kanban-column-container"> | ||
{{ column.title }} | ||
<span class="kanban-column-content"> | ||
{{ column.tasks.length }} | ||
</span> | ||
</div> | ||
<TaskCard v-for="task in column.tasks" :key="task.title" :task="task" /> | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
import TaskCard from './taskCard.vue'; | ||
import axios from 'axios'; | ||
|
||
export default { | ||
name: 'App', | ||
components: { TaskCard }, | ||
data() { | ||
return { | ||
columns: [], | ||
}; | ||
}, | ||
mounted() { | ||
axios | ||
.get('https://demo.lunalytics.xyz/api/kanban') | ||
.then((response) => (this.columns = response)); | ||
}, | ||
}; | ||
</script> | ||
|
||
<style scoped> | ||
.kanban-container { | ||
display: flex; | ||
flex-direction: column; | ||
gap: 20px; | ||
margin-top: 16px; | ||
} | ||
|
||
.kanban-column { | ||
background-color: var(--vp-c-brand-dimm); | ||
padding: 8px 10px 16px 10px; | ||
border-radius: 12px; | ||
flex: 1; | ||
} | ||
|
||
.kanban-column-container { | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
gap: 8px; | ||
font-weight: 600; | ||
} | ||
|
||
.kanban-column-content { | ||
font-weight: 600; | ||
color: var(--vp-c-brand); | ||
background-color: var(--vp-c-brand-light); | ||
border-radius: 100%; | ||
text-align: center; | ||
width: 20px; | ||
height: 20px; | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
font-size: 14px; | ||
color: black; | ||
} | ||
|
||
@media only screen and (min-width: 1100px) { | ||
.kanban-container { | ||
flex-direction: row; | ||
gap: 16px; | ||
} | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
<template> | ||
<div class="kanban-task"> | ||
<div :style="{ display: 'flex', justifyContent: 'space-between' }"> | ||
<badge v-if="task.type" :color="badgeColor">{{ task.type }}</badge> | ||
<a v-if="task.link" class="link-container" :href="task.link">🔗</a> | ||
</div> | ||
|
||
<div class="kanban-title"> | ||
{{ task.title }} | ||
</div> | ||
|
||
<div class="kanban-description"> | ||
{{ task.description }} | ||
</div> | ||
|
||
<div | ||
:style="{ | ||
display: 'flex', | ||
justifyContent: 'flex-end', | ||
color: '#a5a5a5', | ||
}" | ||
> | ||
📅 {{ task.date }} | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
import Badge from './badge.vue'; | ||
export default { | ||
components: { | ||
Badge, | ||
}, | ||
props: { | ||
task: { | ||
type: Object, | ||
default: () => ({}), | ||
}, | ||
}, | ||
computed: { | ||
badgeColor() { | ||
const mappings = { | ||
Low: { background: '#6d6d6d', color: 'white' }, | ||
Medium: { background: '#e9c739', color: '#222222' }, | ||
High: { background: '#d92f20', color: 'white' }, | ||
Bug: { background: '#fb8a31', color: '#222222' }, | ||
Design: { background: '#8f44e1', color: 'white' }, | ||
Complete: { background: '#00b846', color: 'white' }, | ||
default: { background: '#8f44e1', color: 'white' }, | ||
}; | ||
return mappings[this.task.type] || mappings.default; | ||
}, | ||
}, | ||
}; | ||
</script> | ||
|
||
<style scoped> | ||
.kanban-task { | ||
display: flex; | ||
flex-direction: column; | ||
gap: 8px; | ||
margin-top: 10px; | ||
padding: 8px 10px; | ||
border-radius: 12px; | ||
background-color: var(--vp-c-brand-dimm); | ||
} | ||
.kanban-title { | ||
font-size: 18px; | ||
font-weight: 600; | ||
color: white; | ||
margin: 0; | ||
padding: 0; | ||
text-align: left; | ||
margin: 6px 0 4px 0; | ||
} | ||
.kanban-description { | ||
font-size: 14px; | ||
font-weight: 400; | ||
color: #bbbbbb; | ||
margin: 0; | ||
padding: 0; | ||
text-align: left; | ||
} | ||
.link-container { | ||
display: flex; | ||
padding: 4px; | ||
align-items: center; | ||
gap: 4px; | ||
background-color: var(--vp-c-brand-dimm); | ||
border-radius: 8px; | ||
cursor: pointer; | ||
text-decoration: none; | ||
} | ||
.link-container:hover { | ||
background-color: var(--vp-c-brand-darker); | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
# Configuration | ||
|
||
## Setup Lunalytics | ||
|
||
Configurations don't need to be setup before starting Lunalytics. But this it is HIGHLY recommended you run the setup script or create a `config.json` for security reasons. A script can be created by running the following command: | ||
|
||
::: code-group | ||
|
||
```bash [npm] | ||
# Setup application | ||
npm run setup | ||
``` | ||
|
||
```bash [yarn] | ||
# Setup application | ||
yarn setup | ||
``` | ||
|
||
```bash [pnpm] | ||
# Setup application | ||
pnpm setup | ||
|
||
``` | ||
|
||
::: | ||
|
||
The following values need to be added to the config.json file: | ||
|
||
::: code-group | ||
|
||
```json [config.json] | ||
{ | ||
"port": Number, | ||
"jwtSecret": String, | ||
"migrationType": String, | ||
"database": { | ||
"name": String | ||
}, | ||
"version": String, | ||
"isDemo": Boolean | ||
} | ||
``` | ||
|
||
::: | ||
|
||
### Port | ||
|
||
Port needs to be a number between 1 and 65535. The application will be hosted on this port. | ||
|
||
### JWT Secret Key | ||
|
||
We use Json Web Tokens (JWT) to authenticate users. The JWT is signed using a secret key, and then stored in the users cookies. Any requests made to the API is verified using the JWT token (`access_token` cookie). We strongly recommend the JWT secret key being at least 64 bytes. | ||
|
||
### Migration Type | ||
|
||
Migration type can be one of the following: | ||
|
||
- automatic | ||
- manual | ||
|
||
When migration type is set to `automatic`, the application will automatically run migrations, when the latest version is pulled from GitHub. When it is set to `manual`, the application will not run migrations. You can manually run migrations using the `npm run migrate` command. | ||
|
||
### Database | ||
|
||
Database is an Object that contains a name key with the name of the database. In the future this will be expanded with other database options. | ||
|
||
### Version | ||
|
||
Version is the current version of the application. This is used in the migrations script to determine which migrations to run. For example, if the version is `0.4.0` and the latest version is `0.5.0`, then migrations from `0.4.0` to `0.5.0` will be run. | ||
|
||
### isDemo | ||
|
||
isDemo is a boolean that is used to determine if the application is in demo mode. When it is in demo mode, users will not be required to log into the application and will be given access to the application as a `guest` user. |
Empty file.
Empty file.
Empty file.
Oops, something went wrong.