File tree 5 files changed +15
-9
lines changed
packages/@liexp/ui/src/components/admin
services/admin-web/src/pages/actors 5 files changed +15
-9
lines changed Original file line number Diff line number Diff line change @@ -106,6 +106,8 @@ export const ShareModalContent: React.FC<ShareModalContentProps> = ({
106
106
< GroupList
107
107
groups = { ( payload ?. groups ?? [ ] ) . map ( ( g ) => ( {
108
108
...g ,
109
+ body : null ,
110
+ excerpt : null ,
109
111
selected : true ,
110
112
} ) ) }
111
113
onItemClick = { ( ) => { } }
Original file line number Diff line number Diff line change 1
1
import * as SocialPost from "@liexp/shared/lib/io/http/SocialPost.js" ;
2
2
import * as React from "react" ;
3
3
import { Box , Stack } from "../../mui/index.js" ;
4
- import { SelectInput } from "../react-admin.js" ;
4
+ import { SelectInput , useRecordContext } from "../react-admin.js" ;
5
5
import { PublishNowButton } from "./PublishNowButton.js" ;
6
6
7
7
export const SocialPostStatus : React . FC = ( ) => {
8
+ const record = useRecordContext ( ) ;
8
9
return (
9
10
< Stack
10
11
direction = "row"
@@ -22,7 +23,9 @@ export const SocialPostStatus: React.FC = () => {
22
23
} ) ) }
23
24
/>
24
25
< Box >
25
- < PublishNowButton platforms = { { IG : true , TG : true } } />
26
+ < PublishNowButton
27
+ platforms = { record ?. platforms ?? { IG : false , TG : true } }
28
+ />
26
29
</ Box >
27
30
</ Stack >
28
31
) ;
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ import {
11
11
type Identifier ,
12
12
} from "react-admin" ;
13
13
import { useConfiguration } from "../../../context/ConfigurationContext.js" ;
14
- import { Box , Button } from "../../mui/index.js" ;
14
+ import { Button , Stack } from "../../mui/index.js" ;
15
15
import { ShareModal , emptySharePayload } from "../Modal/ShareModal.js" ;
16
16
17
17
interface OnLoadSharePayloadClickOpts {
@@ -42,7 +42,7 @@ export const SocialPostButton: React.FC<SocialPostButtonProps> = ({
42
42
} > ( { payload : emptySharePayload , multipleMedia : false , media : [ ] } ) ;
43
43
44
44
return (
45
- < Box style = { { display : "flex" , marginRight : 10 } } >
45
+ < Stack spacing = { 2 } >
46
46
< Button
47
47
color = "secondary"
48
48
variant = "contained"
@@ -84,6 +84,6 @@ export const SocialPostButton: React.FC<SocialPostButtonProps> = ({
84
84
} }
85
85
/>
86
86
) : null }
87
- </ Box >
87
+ </ Stack >
88
88
) ;
89
89
} ;
Original file line number Diff line number Diff line change @@ -52,8 +52,10 @@ export const LinkEdit: React.FC = () => {
52
52
title = { < EditTitle /> }
53
53
actions = {
54
54
< Toolbar >
55
- < UpdateMetadataButton />
56
- < LinkTGPostButton />
55
+ < Stack direction = "row" spacing = { 2 } >
56
+ < UpdateMetadataButton />
57
+ < LinkTGPostButton />
58
+ </ Stack >
57
59
</ Toolbar >
58
60
}
59
61
preview = { < LinkPreview record = { record } /> }
Original file line number Diff line number Diff line change @@ -24,7 +24,6 @@ import {
24
24
Datagrid ,
25
25
DateField ,
26
26
DateInput ,
27
- FormTab ,
28
27
FunctionField ,
29
28
ImageField ,
30
29
ImageInput ,
@@ -36,13 +35,13 @@ import {
36
35
type EditProps ,
37
36
} from "@liexp/ui/lib/components/admin/react-admin.js" ;
38
37
import { LazyFormTabContent } from "@liexp/ui/lib/components/admin/tabs/LazyFormTabContent.js" ;
38
+ import { Grid } from "@liexp/ui/lib/components/mui/index.js" ;
39
39
import { useDataProvider } from "@liexp/ui/lib/hooks/useDataProvider.js" ;
40
40
import { type Option } from "effect/Option" ;
41
41
import * as O from "fp-ts/lib/Option.js" ;
42
42
import { pipe } from "fp-ts/lib/function.js" ;
43
43
import * as React from "react" ;
44
44
import { transformActor } from "./ActorCreate" ;
45
- import { Grid , Stack } from "@liexp/ui/lib/components/mui/index.js" ;
46
45
47
46
const EditTitle : React . FC = ( ) => {
48
47
const record = useRecordContext ( ) ;
You can’t perform that action at this time.
0 commit comments