add stylelint

This commit is contained in:
41666 2019-04-03 01:53:46 -05:00
parent 47a2e5694e
commit 928c9cf07c
No known key found for this signature in database
GPG key ID: BC51D07640DC10AF
83 changed files with 10807 additions and 1770 deletions

View file

@ -0,0 +1,9 @@
// @flow
export type Category = {
hidden: boolean,
name: string,
roles: string[],
_roles?: any,
type: 'single' | 'multi' | string
}

View file

@ -0,0 +1,21 @@
// @flow
export type {
PresentableRole,
CachedRole,
Permissions
} from './role'
export type {
PresentableServer,
ServerModel,
ServerSlug
} from './server'
export type {
Category
} from './category'
export type {
UserPartial,
Member
} from './user'

View file

@ -0,0 +1,5 @@
{
"name": "@roleypoly/types",
"version": "2.0.0",
"private": true
}

View file

@ -0,0 +1,22 @@
// @flow
export type PresentableRole = {
id: string,
color: number,
name: string,
position: number,
safe: boolean
}
export type Permissions = {
canManageRoles: boolean,
isAdmin: boolean,
faked?: boolean,
__faked?: Permissions
}
export type CachedRole = {
id: string,
position: number,
color?: number
}

View file

@ -0,0 +1,30 @@
// @flow
import type { Category } from './category'
import type { PresentableRole, Permissions } from './role'
export type ServerSlug = {
id: string,
name: string,
ownerID: string,
icon: string
}
export type ServerModel = {
id: string,
categories: {
[uuid: string]: Category
},
message: string
}
export type PresentableServer = ServerModel & {
id: string,
gm?: {
color: number | string,
nickname: string,
roles: string[]
},
server: ServerSlug,
roles: ?PresentableRole[],
perms: Permissions
}

View file

@ -0,0 +1,14 @@
// @flow
import type { Member as ErisMember } from 'eris'
export type UserPartial = {
id: string,
username: string,
discriminator: string,
avatar: string
}
export type Member = ErisMember & {
color?: number,
__faked?: true
}