Skip to content

Commit ba6986f

Browse files
authored
Merge pull request #86 from IntersectMBO/qa
Fom Qa to pre prod
2 parents 660f4a2 + c9029df commit ba6986f

File tree

4 files changed

+16
-47
lines changed

4 files changed

+16
-47
lines changed

pdf-ui/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
88
As a minor extension, we also keep a semantic version for the `UNRELEASED`
99
changes.
1010

11+
## [v0.5.10](https://www.npmjs.com/package/@intersect.mbo/pdf-ui/v/0.5.11) 2025-01-29
12+
### Fixed
13+
- Proposal rendering fix
14+
1115
## [v0.5.10](https://www.npmjs.com/package/@intersect.mbo/pdf-ui/v/0.5.10) 2025-01-29
1216
### Fixed
1317
- Some typo fixes.

pdf-ui/package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pdf-ui/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@intersect.mbo/pdf-ui",
3-
"version": "0.5.10",
3+
"version": "0.5.11",
44
"description": "Proposal discussion ui",
55
"main": "./src/index.js",
66
"exports": {

pdf-ui/src/pages/ProposedGovernanceActions/SingleGovernanceAction/index.jsx

Lines changed: 10 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1049,8 +1049,6 @@ const SingleGovernanceAction = ({ id }) => {
10491049
</Typography>
10501050
<ReactMarkdown>
10511051
{showFullText || !maxLength ? AbstractMarkdownText : truncatedText}
1052-
1053-
10541052
</ReactMarkdown>
10551053
{!showFullText && maxLength && totalCharLength > maxLength && (
10561054
<Button
@@ -1071,69 +1069,37 @@ const SingleGovernanceAction = ({ id }) => {
10711069
</Button>)}
10721070
</Box>
10731071
{showFullText && (
1074-
<>
1072+
10751073
<Box mt={4}>
10761074
<Typography
10771075
variant='caption'
10781076
sx={{
10791077
color: (theme) => theme?.palette?.text?.grey,
10801078
}}
10811079
>
1082-
Motivation
1080+
Motivation
10831081
</Typography>
1084-
<ReactMarkdown
1085-
components={{
1086-
p(props) {
1087-
const { children } = props;
1088-
return (
1089-
<Typography
1090-
variant='body2'
1091-
data-testid='motivation-content'
1092-
style={{
1093-
wordWrap: 'break-word',
1094-
}}
1095-
>
1096-
{children}
1097-
</Typography>
1098-
);
1099-
},
1100-
}}
1101-
>
1082+
<ReactMarkdown>
11021083
{proposal?.attributes?.content
11031084
?.attributes?.prop_motivation || ''}
11041085
</ReactMarkdown>
1105-
</Box>
1086+
</Box>)}
1087+
{showFullText && (
11061088
<Box mt={4}>
11071089
<Typography
11081090
variant='caption'
11091091
sx={{
11101092
color: (theme) => theme?.palette?.text?.grey,
11111093
}}
11121094
>
1113-
Rationale
1095+
Rationale
11141096
</Typography>
1115-
<ReactMarkdown
1116-
components={{
1117-
p(props) {
1118-
const { children } = props;
1119-
return (
1120-
<Typography
1121-
variant='body2'
1122-
data-testid='rationale-content'
1123-
style={{
1124-
wordWrap: 'break-word',
1125-
}}
1126-
>
1127-
{children}
1128-
</Typography>
1129-
);
1130-
},
1131-
}}
1132-
>
1097+
<ReactMarkdown>
11331098
{proposal?.attributes?.content
11341099
?.attributes?.prop_rationale || ''}
11351100
</ReactMarkdown>
1136-
</Box>
1101+
</Box>)}
1102+
{showFullText && (
11371103
<Button
11381104
variant="text"
11391105
onClick={() => setShowFullText(!showFullText)}
@@ -1149,8 +1115,7 @@ const SingleGovernanceAction = ({ id }) => {
11491115
}}
11501116
>
11511117
{showFullText ? 'Show less' : 'Read more'}
1152-
</Button>
1153-
</>
1118+
</Button>
11541119
)}
11551120
{proposal?.attributes?.content?.attributes
11561121
?.proposal_links?.length > 0 && (

0 commit comments

Comments
 (0)