linting-passing-ritual-dance

This commit is contained in:
tonyrewin 2022-11-27 21:36:45 +03:00
parent 88fb1f47be
commit 238449ba1d
6 changed files with 22 additions and 14 deletions

View File

@ -1,3 +1,9 @@
[0.7.0]
[+] inbox: context provider, chats
[+] comments: show
[+] session: context provider
[+] views tracker: counting for shouts
[0.6.1] [0.6.1]
[+] auth ver. 0.9 [+] auth ver. 0.9
[+] load-by interfaces for shouts, authors and messages [+] load-by interfaces for shouts, authors and messages

View File

@ -1,4 +1,8 @@
# How to start
If you use yarn
``` ```
yarn install yarn
npm start PUBLIC_API_URL=https://v2.discours.io yarn dev
``` ```

View File

@ -1,6 +1,6 @@
{ {
"name": "discoursio-webapp", "name": "discoursio-webapp",
"version": "0.6.1", "version": "0.7.0",
"private": true, "private": true,
"license": "MIT", "license": "MIT",
"scripts": { "scripts": {

View File

@ -1,4 +1,4 @@
import { For, Show } from 'solid-js/web' import { For, Show } from 'solid-js'
import { useSession } from '../../context/session' import { useSession } from '../../context/session'
import Comment from './Comment' import Comment from './Comment'
import { t } from '../../utils/intl' import { t } from '../../utils/intl'

View File

@ -1,29 +1,27 @@
import styles from './DialogCard.module.scss' import styles from './DialogCard.module.scss'
import DialogAvatar from './DialogAvatar' import DialogAvatar from './DialogAvatar'
import type { Author, User } from '../../graphql/types.gen' import type { Author, ChatMember, User } from '../../graphql/types.gen'
import { apiClient } from '../../utils/apiClient'
import { t } from '../../utils/intl' import { t } from '../../utils/intl'
import { useInbox } from '../../context/inbox'
type DialogProps = { type DialogProps = {
online?: boolean online?: boolean
message?: string message?: string
counter?: number counter?: number
users: User[] members: ChatMember[]
ownSlug: User['slug'] ownSlug: User['slug']
} }
const DialogCard = (props: DialogProps) => { const DialogCard = (props: DialogProps) => {
// @ts-ignore const participants = props.members.filter((m) => m.slug !== props.ownSlug)
const participants = props.users.filter((user) => user !== props.ownSlug)
console.log('!!! participants:', participants) console.log('!!! participants:', participants)
// @ts-ignore
return ( return (
//DialogCardView - подумать //DialogCardView - подумать
<div class={styles.DialogCard}> <div class={styles.DialogCard}>
<div class={styles.avatar}>{/*<DialogAvatar name={participants[0]} online={props.online} />*/}</div> <div class={styles.avatar}>
<DialogAvatar name={participants[0].name} online={props.online} />
</div>
<div class={styles.row}> <div class={styles.row}>
{/*<div class={styles.name}>{participants[0]}</div>*/} <div class={styles.name}>{participants[0].name}</div>
<div class={styles.message}> <div class={styles.message}>
Указать предпочтительные языки для результатов поиска можно в разделе Указать предпочтительные языки для результатов поиска можно в разделе
</div> </div>

View File

@ -167,7 +167,7 @@ export const InboxView = () => {
<div class="holder"> <div class="holder">
<div class="dialogs"> <div class="dialogs">
<For each={chats()}> <For each={chats()}>
{(chat) => <DialogCard users={chat.users} ownSlug={currentSlug()} />} {(chat) => <DialogCard members={chat.members} ownSlug={currentSlug()} />}
</For> </For>
</div> </div>
</div> </div>