File tree 3 files changed +6
-6
lines changed
packages/next/src/views/Version
3 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -83,10 +83,10 @@ export const DefaultVersionView: React.FC<DefaultVersionsViewProps> = ({
83
83
current . set ( 'localeCodes' , JSON . stringify ( selectedLocales . map ( ( locale ) => locale . value ) ) )
84
84
}
85
85
86
- if ( ! modifiedOnly ) {
87
- current . delete ( 'modifiedOnly' )
86
+ if ( modifiedOnly === false ) {
87
+ current . set ( 'modifiedOnly' , 'false ')
88
88
} else {
89
- current . set ( 'modifiedOnly' , 'true ')
89
+ current . delete ( 'modifiedOnly' )
90
90
}
91
91
92
92
const search = current . toString ( )
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ export async function VersionView(props: DocumentViewServerProps) {
40
40
41
41
const comparisonVersionIDFromParams : string = searchParams . compareValue as string
42
42
43
- const modifiedOnly : boolean = searchParams . modifiedOnly === 'true'
43
+ const modifiedOnly : boolean = searchParams . modifiedOnly === 'false' ? false : true
44
44
45
45
const { localization } = config
46
46
Original file line number Diff line number Diff line change @@ -1197,11 +1197,11 @@ describe('Versions', () => {
1197
1197
1198
1198
const textInArrayES = page . locator ( '[data-field-path="arrayLocalized"][data-locale="es"]' )
1199
1199
1200
- await expect ( textInArrayES ) . toContainText ( 'No Array Localizeds found' )
1200
+ await expect ( textInArrayES ) . toBeHidden ( )
1201
1201
1202
1202
await page . locator ( '#modifiedOnly' ) . click ( )
1203
1203
1204
- await expect ( textInArrayES ) . toBeHidden ( )
1204
+ await expect ( textInArrayES ) . toContainText ( 'No Array Localizeds found' )
1205
1205
} )
1206
1206
1207
1207
test ( 'correctly renders diff for block fields' , async ( ) => {
You can’t perform that action at this time.
0 commit comments