upd: redesign
Deskripsi: - pengumuman - list dan detail diskusi umum - list dan detail diskusi divisi NO Issues
This commit is contained in:
@@ -113,7 +113,7 @@ export default function Announcement() {
|
||||
bgColor="transparent"
|
||||
icon={
|
||||
// <View style={[Styles.iconContent]}>
|
||||
<MaterialIcons name="campaign" size={25} color={'white'} />
|
||||
<MaterialIcons name="campaign" size={25} color={colors.text} />
|
||||
// </View>
|
||||
}
|
||||
title={item.title}
|
||||
|
||||
@@ -259,7 +259,8 @@ export default function DetailDiscussionGeneral() {
|
||||
<BorderBottomItem2
|
||||
dataFile={fileDiscussion}
|
||||
descEllipsize={false}
|
||||
borderType="bottom"
|
||||
borderType="all"
|
||||
bgColor="white"
|
||||
icon={
|
||||
<View style={[Styles.iconContent]}>
|
||||
<MaterialIcons name="chat" size={25} color={'black'} />
|
||||
@@ -287,7 +288,7 @@ export default function DetailDiscussionGeneral() {
|
||||
}
|
||||
/>
|
||||
}
|
||||
<View style={[Styles.p15]}>
|
||||
<View style={[Styles.mt10]}>
|
||||
{
|
||||
loadingKomentar ?
|
||||
arrSkeleton.map((item: any, i: number) => {
|
||||
@@ -300,7 +301,7 @@ export default function DetailDiscussionGeneral() {
|
||||
return (
|
||||
<BorderBottomItem
|
||||
key={i}
|
||||
borderType="bottom"
|
||||
borderType="all"
|
||||
colorPress
|
||||
icon={
|
||||
<ImageUser src={`${ConstEnv.url_storage}/files/${item.img}`} size="xs" />
|
||||
@@ -310,7 +311,7 @@ export default function DetailDiscussionGeneral() {
|
||||
desc={item.comment}
|
||||
rightBottomInfo={item.isEdited ? "Edited" : ""}
|
||||
descEllipsize={detailMore.includes(item.id) ? false : true}
|
||||
bgColor="transparent"
|
||||
bgColor="white"
|
||||
onPress={() => {
|
||||
setDetailMore((prev: any) => {
|
||||
if (prev.includes(item.id)) {
|
||||
|
||||
@@ -153,9 +153,9 @@ export default function Discussion() {
|
||||
onPress={() => { router.push(`/discussion/${item.id}`) }}
|
||||
borderType="bottom"
|
||||
icon={
|
||||
<View style={[Styles.iconContent]}>
|
||||
<MaterialIcons name="chat" size={25} color={'black'} />
|
||||
</View>
|
||||
// <View style={[Styles.iconContent]}>
|
||||
<MaterialIcons name="chat" size={25} color={colors.text} />
|
||||
// </View>
|
||||
}
|
||||
title={item.title}
|
||||
subtitle={
|
||||
|
||||
@@ -327,7 +327,8 @@ export default function DiscussionDetail() {
|
||||
<BorderBottomItem2
|
||||
dataFile={fileDiscussion}
|
||||
descEllipsize={false}
|
||||
borderType="bottom"
|
||||
bgColor="white"
|
||||
borderType="all"
|
||||
icon={
|
||||
<ImageUser
|
||||
src={`${ConstEnv.url_storage}/files/${data?.user_img}`}
|
||||
@@ -364,7 +365,7 @@ export default function DiscussionDetail() {
|
||||
/>
|
||||
}
|
||||
|
||||
<View style={[Styles.p15]}>
|
||||
<View style={[Styles.mt10]}>
|
||||
{
|
||||
loadingKomentar ?
|
||||
arrSkeleton.map((item, index) => (
|
||||
@@ -374,7 +375,7 @@ export default function DiscussionDetail() {
|
||||
dataComment.map((item, index) => (
|
||||
<BorderBottomItem
|
||||
key={index}
|
||||
borderType="bottom"
|
||||
borderType="all"
|
||||
colorPress
|
||||
icon={
|
||||
<ImageUser
|
||||
@@ -387,7 +388,7 @@ export default function DiscussionDetail() {
|
||||
desc={item.comment}
|
||||
rightBottomInfo={item.isEdited ? "Edited" : ""}
|
||||
descEllipsize={detailMore.includes(item.id) ? false : true}
|
||||
bgColor="transparent"
|
||||
bgColor="white"
|
||||
onPress={() => {
|
||||
setDetailMore((prev: any) => {
|
||||
if (prev.includes(item.id)) {
|
||||
@@ -465,8 +466,8 @@ export default function DiscussionDetail() {
|
||||
size={25}
|
||||
style={
|
||||
[selectKomentar.comment == "" || regexOnlySpacesOrEnter.test(selectKomentar.comment) || loadingSend || ((entityUser.role == "user" || entityUser.role == "coadmin") && !isMemberDivision)
|
||||
? Styles.cGray
|
||||
: Styles.cDefault,
|
||||
? { color: colors.dimmed }
|
||||
: { color: colors.tint },
|
||||
]
|
||||
}
|
||||
/>
|
||||
@@ -479,7 +480,6 @@ export default function DiscussionDetail() {
|
||||
isMemberDivision)
|
||||
?
|
||||
<InputForm
|
||||
bg={colors.card}
|
||||
type="default"
|
||||
round
|
||||
multiline
|
||||
@@ -512,8 +512,8 @@ export default function DiscussionDetail() {
|
||||
size={25}
|
||||
style={
|
||||
[komentar == "" || regexOnlySpacesOrEnter.test(komentar) || loadingSend || ((entityUser.role == "user" || entityUser.role == "coadmin") && !isMemberDivision)
|
||||
? Styles.cGray
|
||||
: Styles.cDefault,
|
||||
? { color: colors.dimmed }
|
||||
: { color: colors.tint }
|
||||
]
|
||||
}
|
||||
/>
|
||||
|
||||
@@ -177,7 +177,7 @@ export default function DiscussionDivision() {
|
||||
onPress={() => { router.push(`./discussion/${item.id}`) }}
|
||||
borderType="bottom"
|
||||
icon={
|
||||
<ImageUser src={`${ConstEnv.url_storage}/files/${item.img}`} size="sm" />
|
||||
<ImageUser src={`${ConstEnv.url_storage}/files/${item.img}`} size="xs" />
|
||||
}
|
||||
title={item.user_name}
|
||||
subtitle={
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
import { ColorsStatus } from "@/constants/ColorsStatus";
|
||||
import Styles from "@/constants/Styles";
|
||||
import { useTheme } from "@/providers/ThemeProvider";
|
||||
import React, { useState } from "react";
|
||||
import { Dimensions, Pressable, View } from "react-native";
|
||||
import { Pressable, View } from "react-native";
|
||||
import Text from "./Text";
|
||||
|
||||
type Props = {
|
||||
@@ -69,7 +68,7 @@ export default function BorderBottomItem({ title, subtitle, icon, desc, onPress,
|
||||
{
|
||||
(leftBottomInfo || rightBottomInfo) &&
|
||||
(
|
||||
<View style={[rightBottomInfo && !leftBottomInfo ? Styles.rowSpaceBetweenReverse : Styles.rowSpaceBetween, Styles.mt05]}>
|
||||
<View style={[rightBottomInfo && !leftBottomInfo ? Styles.rowSpaceBetweenReverse : Styles.rowSpaceBetween, Styles.mt02]}>
|
||||
{
|
||||
typeof leftBottomInfo == 'string' ?
|
||||
<Text style={[Styles.textInformation, { color: colors.dimmed }]}>{leftBottomInfo}</Text>
|
||||
|
||||
@@ -149,7 +149,7 @@ export default function BorderBottomItem2({ title, subtitle, icon, desc, onPress
|
||||
{desc && <Text style={[Styles.textDefault, Styles.mt05, { textAlign: 'left', color: textColorFix }]} numberOfLines={descEllipsize == false ? 0 : 2} ellipsizeMode='tail'>{desc}</Text>}
|
||||
{
|
||||
dataFile.length > 0 && (
|
||||
<ScrollView horizontal style={[Styles.mv05]} showsHorizontalScrollIndicator={false}>
|
||||
<ScrollView horizontal style={[Styles.mv10]} showsHorizontalScrollIndicator={false}>
|
||||
{dataFile.map((item, index) => (
|
||||
<Pressable
|
||||
key={index}
|
||||
@@ -173,7 +173,7 @@ export default function BorderBottomItem2({ title, subtitle, icon, desc, onPress
|
||||
{
|
||||
(leftBottomInfo || rightBottomInfo) &&
|
||||
(
|
||||
<View style={[rightBottomInfo && !leftBottomInfo ? Styles.rowSpaceBetweenReverse : Styles.rowSpaceBetween, Styles.mt05]}>
|
||||
<View style={[rightBottomInfo && !leftBottomInfo ? Styles.rowSpaceBetweenReverse : Styles.rowSpaceBetween, Styles.mt10]}>
|
||||
{
|
||||
typeof leftBottomInfo == 'string' ?
|
||||
<Text style={[Styles.textInformation, { color: colors.dimmed }]}>{leftBottomInfo}</Text>
|
||||
|
||||
Reference in New Issue
Block a user