@@ -284,7 +284,8 @@ const DefaultMode = {
284
284
} ,
285
285
} ;
286
286
287
- export const English = Object . assign ( { } , DefaultMode , {
287
+ export const English = {
288
+ ...DefaultMode ,
288
289
description : ReactDOMServer . renderToStaticMarkup ( exp . l (
289
290
`This mode capitalises almost all words, with some words (mainly articles
290
291
and short prepositions) lowercased. Some words may need to be manually
@@ -322,9 +323,10 @@ export const English = Object.assign({}, DefaultMode, {
322
323
is = this . fixEnglishKeyNames ( is ) ;
323
324
return is ;
324
325
} ,
325
- } ) ;
326
+ } ;
326
327
327
- export const French = Object . assign ( { } , DefaultMode , {
328
+ export const French = {
329
+ ...DefaultMode ,
328
330
description : ReactDOMServer . renderToStaticMarkup ( exp . l (
329
331
`This mode capitalises titles as sentence mode, but also inserts spaces
330
332
before semicolons, colons, exclamation marks and question marks,
@@ -345,9 +347,10 @@ export const French = Object.assign({}, DefaultMode, {
345
347
. replace ( / ^ ( L e \s | L a \s | L e s \s | L [ ’ ' ] ) ( \S + ) $ / gi,
346
348
( _ , m1 , m2 ) => m1 . replace ( '\'' , '’' ) + capitalize ( m2 ) ) ;
347
349
} ,
348
- } ) ;
350
+ } ;
349
351
350
- export const Sentence = Object . assign ( { } , DefaultMode , {
352
+ export const Sentence = {
353
+ ...DefaultMode ,
351
354
description : ReactDOMServer . renderToStaticMarkup ( exp . l (
352
355
`This mode capitalises the first word of a sentence, most other words
353
356
are lowercased. Some words, often proper nouns, may need to be manually
@@ -359,8 +362,10 @@ export const Sentence = Object.assign({}, DefaultMode, {
359
362
) ) ,
360
363
361
364
name : 'Sentence' ,
362
- } ) ;
363
- export const Turkish = Object . assign ( { } , DefaultMode , {
365
+ } ;
366
+
367
+ export const Turkish = {
368
+ ...DefaultMode ,
364
369
description : ReactDOMServer . renderToStaticMarkup ( exp . l (
365
370
`This mode handles the Turkish capitalisation of 'i' ('İ') and 'ı' ('I').
366
371
Some words may need to be manually corrected according to
@@ -386,4 +391,4 @@ export const Turkish = Object.assign({}, DefaultMode, {
386
391
toLowerCase : turkishLowerCase ,
387
392
388
393
toUpperCase : turkishUpperCase ,
389
- } ) ;
394
+ } ;
0 commit comments