@git-diff-view/react 0.0.34 → 0.0.36

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -267,10 +267,10 @@
267
267
  }
268
268
  .diff-tailwindcss-wrapper[data-theme="light"] .diff-style-root {
269
269
  --diff-border--: #dedede;
270
- --diff-add-content--: #e6ffec;
270
+ --diff-add-content--: #dafbe1;
271
271
  --diff-del-content--: #ffebe9;
272
- --diff-add-lineNumber--: #ccffd8;
273
- --diff-del-lineNumber--: #ffd7d5;
272
+ --diff-add-lineNumber--: #aceebb;
273
+ --diff-del-lineNumber--: #ffcecb;
274
274
  --diff-plain-content--: #ffffff;
275
275
  --diff-expand-content--: #fafafa;
276
276
  --diff-plain-lineNumber--: #fafafa;
@@ -278,10 +278,10 @@
278
278
  --diff-plain-lineNumber-color--: #555555;
279
279
  --diff-expand-lineNumber-color--: #555555;
280
280
  --diff-hunk-content--: #ddf4ff;
281
- --diff-hunk-lineNumber--: #c7ecff;
281
+ --diff-hunk-lineNumber--: #b6e3ff;
282
282
  --diff-hunk-lineNumber-hover--: #0969da;
283
- --diff-add-content-highlight--: #abf2bc;
284
- --diff-del-content-highlight--: #ffb3ad;
283
+ --diff-add-content-highlight--: #aceebb;
284
+ --diff-del-content-highlight--: #ffcecb;
285
285
  --diff-add-widget--: #0969d2;
286
286
  --diff-add-widget-color--: #ffffff;
287
287
  --diff-empty-content--: #fafafa;
@@ -296,10 +296,10 @@
296
296
  }
297
297
  .diff-tailwindcss-wrapper[data-theme="dark"] .diff-style-root {
298
298
  --diff-border--: #3d444d;
299
- --diff-add-content--: #14261f;
300
- --diff-del-content--: #311b1f;
301
- --diff-add-lineNumber--: #1f4429;
302
- --diff-del-lineNumber--: #552527;
299
+ --diff-add-content--: #18271f;
300
+ --diff-del-content--: #23191c;
301
+ --diff-add-lineNumber--: #284228;
302
+ --diff-del-lineNumber--: #4f2828;
303
303
  --diff-plain-content--: #0d1117;
304
304
  --diff-expand-content--: #161b22;
305
305
  --diff-plain-lineNumber--: #161b22;
@@ -307,10 +307,10 @@
307
307
  --diff-plain-lineNumber-color--: #a0aaab;
308
308
  --diff-expand-lineNumber-color--: #a0aaab;
309
309
  --diff-hunk-content--: #131d2e;
310
- --diff-hunk-lineNumber--: #204274;
310
+ --diff-hunk-lineNumber--: #0c2d6b;
311
311
  --diff-hunk-lineNumber-hover--: #1f6feb;
312
- --diff-add-content-highlight--: #1f572d;
313
- --diff-del-content-highlight--: #80312f;
312
+ --diff-add-content-highlight--: #2f5732;
313
+ --diff-del-content-highlight--: #713431;
314
314
  --diff-add-widget--: #0969d2;
315
315
  --diff-add-widget-color--: #ffffff;
316
316
  --diff-empty-content--: #161b22;
@@ -1,533 +1,27 @@
1
- *, ::before, ::after {
2
- --tw-border-spacing-x: 0;
3
- --tw-border-spacing-y: 0;
4
- --tw-translate-x: 0;
5
- --tw-translate-y: 0;
6
- --tw-rotate: 0;
7
- --tw-skew-x: 0;
8
- --tw-skew-y: 0;
9
- --tw-scale-x: 1;
10
- --tw-scale-y: 1;
11
- --tw-pan-x: ;
12
- --tw-pan-y: ;
13
- --tw-pinch-zoom: ;
14
- --tw-scroll-snap-strictness: proximity;
15
- --tw-gradient-from-position: ;
16
- --tw-gradient-via-position: ;
17
- --tw-gradient-to-position: ;
18
- --tw-ordinal: ;
19
- --tw-slashed-zero: ;
20
- --tw-numeric-figure: ;
21
- --tw-numeric-spacing: ;
22
- --tw-numeric-fraction: ;
23
- --tw-ring-inset: ;
24
- --tw-ring-offset-width: 0px;
25
- --tw-ring-offset-color: #fff;
26
- --tw-ring-color: rgb(59 130 246 / 0.5);
27
- --tw-ring-offset-shadow: 0 0 #0000;
28
- --tw-ring-shadow: 0 0 #0000;
29
- --tw-shadow: 0 0 #0000;
30
- --tw-shadow-colored: 0 0 #0000;
31
- --tw-blur: ;
32
- --tw-brightness: ;
33
- --tw-contrast: ;
34
- --tw-grayscale: ;
35
- --tw-hue-rotate: ;
36
- --tw-invert: ;
37
- --tw-saturate: ;
38
- --tw-sepia: ;
39
- --tw-drop-shadow: ;
40
- --tw-backdrop-blur: ;
41
- --tw-backdrop-brightness: ;
42
- --tw-backdrop-contrast: ;
43
- --tw-backdrop-grayscale: ;
44
- --tw-backdrop-hue-rotate: ;
45
- --tw-backdrop-invert: ;
46
- --tw-backdrop-opacity: ;
47
- --tw-backdrop-saturate: ;
48
- --tw-backdrop-sepia: ;
49
- --tw-contain-size: ;
50
- --tw-contain-layout: ;
51
- --tw-contain-paint: ;
52
- --tw-contain-style: ;
53
- }
54
-
55
- ::backdrop {
56
- --tw-border-spacing-x: 0;
57
- --tw-border-spacing-y: 0;
58
- --tw-translate-x: 0;
59
- --tw-translate-y: 0;
60
- --tw-rotate: 0;
61
- --tw-skew-x: 0;
62
- --tw-skew-y: 0;
63
- --tw-scale-x: 1;
64
- --tw-scale-y: 1;
65
- --tw-pan-x: ;
66
- --tw-pan-y: ;
67
- --tw-pinch-zoom: ;
68
- --tw-scroll-snap-strictness: proximity;
69
- --tw-gradient-from-position: ;
70
- --tw-gradient-via-position: ;
71
- --tw-gradient-to-position: ;
72
- --tw-ordinal: ;
73
- --tw-slashed-zero: ;
74
- --tw-numeric-figure: ;
75
- --tw-numeric-spacing: ;
76
- --tw-numeric-fraction: ;
77
- --tw-ring-inset: ;
78
- --tw-ring-offset-width: 0px;
79
- --tw-ring-offset-color: #fff;
80
- --tw-ring-color: rgb(59 130 246 / 0.5);
81
- --tw-ring-offset-shadow: 0 0 #0000;
82
- --tw-ring-shadow: 0 0 #0000;
83
- --tw-shadow: 0 0 #0000;
84
- --tw-shadow-colored: 0 0 #0000;
85
- --tw-blur: ;
86
- --tw-brightness: ;
87
- --tw-contrast: ;
88
- --tw-grayscale: ;
89
- --tw-hue-rotate: ;
90
- --tw-invert: ;
91
- --tw-saturate: ;
92
- --tw-sepia: ;
93
- --tw-drop-shadow: ;
94
- --tw-backdrop-blur: ;
95
- --tw-backdrop-brightness: ;
96
- --tw-backdrop-contrast: ;
97
- --tw-backdrop-grayscale: ;
98
- --tw-backdrop-hue-rotate: ;
99
- --tw-backdrop-invert: ;
100
- --tw-backdrop-opacity: ;
101
- --tw-backdrop-saturate: ;
102
- --tw-backdrop-sepia: ;
103
- --tw-contain-size: ;
104
- --tw-contain-layout: ;
105
- --tw-contain-paint: ;
106
- --tw-contain-style: ;
107
- }/*
108
- ! tailwindcss v3.4.18 | MIT License | https://tailwindcss.com
109
- *//*
110
- 1. Prevent padding and border from affecting element width. (https://github.com/mozdevs/cssremedy/issues/4)
111
- 2. Allow adding a border to an element by just adding a border-width. (https://github.com/tailwindcss/tailwindcss/pull/116)
112
- */
113
-
114
- *,
115
- ::before,
116
- ::after {
117
- box-sizing: border-box; /* 1 */
118
- border-width: 0; /* 2 */
119
- border-style: solid; /* 2 */
120
- border-color: #e5e7eb; /* 2 */
121
- }
122
-
123
- ::before,
124
- ::after {
125
- --tw-content: '';
126
- }
127
-
128
- /*
129
- 1. Use a consistent sensible line-height in all browsers.
130
- 2. Prevent adjustments of font size after orientation changes in iOS.
131
- 3. Use a more readable tab size.
132
- 4. Use the user's configured `sans` font-family by default.
133
- 5. Use the user's configured `sans` font-feature-settings by default.
134
- 6. Use the user's configured `sans` font-variation-settings by default.
135
- 7. Disable tap highlights on iOS
136
- */
137
-
138
- html,
139
- :host {
140
- line-height: 1.5; /* 1 */
141
- -webkit-text-size-adjust: 100%; /* 2 */
142
- -moz-tab-size: 4; /* 3 */
143
- -o-tab-size: 4;
144
- tab-size: 4; /* 3 */
145
- font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; /* 4 */
146
- font-feature-settings: normal; /* 5 */
147
- font-variation-settings: normal; /* 6 */
148
- -webkit-tap-highlight-color: transparent; /* 7 */
149
- }
150
-
151
- /*
152
- 1. Remove the margin in all browsers.
153
- 2. Inherit line-height from `html` so users can set them as a class directly on the `html` element.
154
- */
155
-
156
- body {
157
- margin: 0; /* 1 */
158
- line-height: inherit; /* 2 */
159
- }
160
-
161
- /*
162
- 1. Add the correct height in Firefox.
163
- 2. Correct the inheritance of border color in Firefox. (https://bugzilla.mozilla.org/show_bug.cgi?id=190655)
164
- 3. Ensure horizontal rules are visible by default.
165
- */
166
-
167
- hr {
168
- height: 0; /* 1 */
169
- color: inherit; /* 2 */
170
- border-top-width: 1px; /* 3 */
171
- }
172
-
173
- /*
174
- Add the correct text decoration in Chrome, Edge, and Safari.
175
- */
176
-
177
- abbr:where([title]) {
178
- -webkit-text-decoration: underline dotted;
179
- text-decoration: underline dotted;
180
- }
181
-
182
- /*
183
- Remove the default font size and weight for headings.
184
- */
185
-
186
- h1,
187
- h2,
188
- h3,
189
- h4,
190
- h5,
191
- h6 {
192
- font-size: inherit;
193
- font-weight: inherit;
194
- }
195
-
196
- /*
197
- Reset links to optimize for opt-in styling instead of opt-out.
198
- */
199
-
200
- a {
201
- color: inherit;
202
- text-decoration: inherit;
203
- }
204
-
205
- /*
206
- Add the correct font weight in Edge and Safari.
207
- */
208
-
209
- b,
210
- strong {
211
- font-weight: bolder;
212
- }
213
-
214
- /*
215
- 1. Use the user's configured `mono` font-family by default.
216
- 2. Use the user's configured `mono` font-feature-settings by default.
217
- 3. Use the user's configured `mono` font-variation-settings by default.
218
- 4. Correct the odd `em` font sizing in all browsers.
219
- */
220
-
221
- code,
222
- kbd,
223
- samp,
224
- pre {
225
- font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; /* 1 */
226
- font-feature-settings: normal; /* 2 */
227
- font-variation-settings: normal; /* 3 */
228
- font-size: 1em; /* 4 */
229
- }
230
-
231
- /*
232
- Add the correct font size in all browsers.
233
- */
234
-
235
- small {
236
- font-size: 80%;
237
- }
238
-
239
- /*
240
- Prevent `sub` and `sup` elements from affecting the line height in all browsers.
241
- */
242
-
243
- sub,
244
- sup {
245
- font-size: 75%;
246
- line-height: 0;
247
- position: relative;
248
- vertical-align: baseline;
249
- }
250
-
251
- sub {
252
- bottom: -0.25em;
253
- }
254
-
255
- sup {
256
- top: -0.5em;
257
- }
258
-
259
- /*
260
- 1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)
261
- 2. Correct table border color inheritance in all Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)
262
- 3. Remove gaps between table borders by default.
263
- */
264
-
265
- table {
266
- text-indent: 0; /* 1 */
267
- border-color: inherit; /* 2 */
268
- border-collapse: collapse; /* 3 */
269
- }
270
-
271
- /*
272
- 1. Change the font styles in all browsers.
273
- 2. Remove the margin in Firefox and Safari.
274
- 3. Remove default padding in all browsers.
275
- */
276
-
277
- button,
278
- input,
279
- optgroup,
280
- select,
281
- textarea {
282
- font-family: inherit; /* 1 */
283
- font-feature-settings: inherit; /* 1 */
284
- font-variation-settings: inherit; /* 1 */
285
- font-size: 100%; /* 1 */
286
- font-weight: inherit; /* 1 */
287
- line-height: inherit; /* 1 */
288
- letter-spacing: inherit; /* 1 */
289
- color: inherit; /* 1 */
290
- margin: 0; /* 2 */
291
- padding: 0; /* 3 */
292
- }
293
-
294
- /*
295
- Remove the inheritance of text transform in Edge and Firefox.
296
- */
297
-
298
- button,
299
- select {
300
- text-transform: none;
301
- }
302
-
303
- /*
304
- 1. Correct the inability to style clickable types in iOS and Safari.
305
- 2. Remove default button styles.
306
- */
307
-
308
- button,
309
- input:where([type='button']),
310
- input:where([type='reset']),
311
- input:where([type='submit']) {
312
- -webkit-appearance: button; /* 1 */
313
- background-color: transparent; /* 2 */
314
- background-image: none; /* 2 */
315
- }
316
-
317
- /*
318
- Use the modern Firefox focus style for all focusable elements.
319
- */
320
-
321
- :-moz-focusring {
322
- outline: auto;
323
- }
324
-
325
- /*
326
- Remove the additional `:invalid` styles in Firefox. (https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737)
327
- */
328
-
329
- :-moz-ui-invalid {
330
- box-shadow: none;
331
- }
332
-
333
- /*
334
- Add the correct vertical alignment in Chrome and Firefox.
335
- */
336
-
337
- progress {
338
- vertical-align: baseline;
339
- }
340
-
341
- /*
342
- Correct the cursor style of increment and decrement buttons in Safari.
343
- */
344
-
345
- ::-webkit-inner-spin-button,
346
- ::-webkit-outer-spin-button {
347
- height: auto;
348
- }
349
-
350
- /*
351
- 1. Correct the odd appearance in Chrome and Safari.
352
- 2. Correct the outline style in Safari.
353
- */
354
-
355
- [type='search'] {
356
- -webkit-appearance: textfield; /* 1 */
357
- outline-offset: -2px; /* 2 */
358
- }
359
-
360
- /*
361
- Remove the inner padding in Chrome and Safari on macOS.
362
- */
363
-
364
- ::-webkit-search-decoration {
365
- -webkit-appearance: none;
366
- }
367
-
368
- /*
369
- 1. Correct the inability to style clickable types in iOS and Safari.
370
- 2. Change font properties to `inherit` in Safari.
371
- */
372
-
373
- ::-webkit-file-upload-button {
374
- -webkit-appearance: button; /* 1 */
375
- font: inherit; /* 2 */
376
- }
377
-
378
- /*
379
- Add the correct display in Chrome and Safari.
380
- */
381
-
382
- summary {
383
- display: list-item;
384
- }
385
-
386
- /*
387
- Removes the default spacing and border for appropriate elements.
388
- */
389
-
390
- blockquote,
391
- dl,
392
- dd,
393
- h1,
394
- h2,
395
- h3,
396
- h4,
397
- h5,
398
- h6,
399
- hr,
400
- figure,
401
- p,
402
- pre {
403
- margin: 0;
404
- }
405
-
406
- fieldset {
407
- margin: 0;
408
- padding: 0;
409
- }
410
-
411
- legend {
412
- padding: 0;
413
- }
414
-
415
- ol,
416
- ul,
417
- menu {
418
- list-style: none;
419
- margin: 0;
420
- padding: 0;
421
- }
422
-
423
- /*
424
- Reset default styling for dialogs.
425
- */
426
- dialog {
427
- padding: 0;
428
- }
429
-
430
- /*
431
- Prevent resizing textareas horizontally by default.
432
- */
433
-
434
- textarea {
435
- resize: vertical;
436
- }
437
-
438
- /*
439
- 1. Reset the default placeholder opacity in Firefox. (https://github.com/tailwindlabs/tailwindcss/issues/3300)
440
- 2. Set the default placeholder color to the user's configured gray 400 color.
441
- */
442
-
443
- input::-moz-placeholder, textarea::-moz-placeholder {
444
- opacity: 1; /* 1 */
445
- color: #9ca3af; /* 2 */
446
- }
447
-
448
- input::placeholder,
449
- textarea::placeholder {
450
- opacity: 1; /* 1 */
451
- color: #9ca3af; /* 2 */
452
- }
453
-
454
- /*
455
- Set the default cursor for buttons.
456
- */
457
-
458
- button,
459
- [role="button"] {
460
- cursor: pointer;
461
- }
462
-
463
- /*
464
- Make sure disabled buttons don't get the pointer cursor.
465
- */
466
- :disabled {
467
- cursor: default;
468
- }
469
-
470
- /*
471
- 1. Make replaced elements `display: block` by default. (https://github.com/mozdevs/cssremedy/issues/14)
472
- 2. Add `vertical-align: middle` to align replaced elements more sensibly by default. (https://github.com/jensimmons/cssremedy/issues/14#issuecomment-634934210)
473
- This can trigger a poorly considered lint error in some tools but is included by design.
474
- */
475
-
476
- img,
477
- svg,
478
- video,
479
- canvas,
480
- audio,
481
- iframe,
482
- embed,
483
- object {
484
- display: block; /* 1 */
485
- vertical-align: middle; /* 2 */
486
- }
487
-
488
- /*
489
- Constrain images and videos to the parent width and preserve their intrinsic aspect ratio. (https://github.com/mozdevs/cssremedy/issues/14)
490
- */
491
-
492
- img,
493
- video {
494
- max-width: 100%;
495
- height: auto;
496
- }
497
-
498
- /* Make elements with the HTML hidden attribute stay hidden by default */
499
- [hidden]:where(:not([hidden="until-found"])) {
500
- display: none;
501
- }
502
1
  .diff-tailwindcss-wrapper .container {
503
2
  width: 100%;
504
3
  }
505
4
  @media (min-width: 640px) {
506
-
507
5
  .diff-tailwindcss-wrapper .container {
508
6
  max-width: 640px;
509
7
  }
510
8
  }
511
9
  @media (min-width: 768px) {
512
-
513
10
  .diff-tailwindcss-wrapper .container {
514
11
  max-width: 768px;
515
12
  }
516
13
  }
517
14
  @media (min-width: 1024px) {
518
-
519
15
  .diff-tailwindcss-wrapper .container {
520
16
  max-width: 1024px;
521
17
  }
522
18
  }
523
19
  @media (min-width: 1280px) {
524
-
525
20
  .diff-tailwindcss-wrapper .container {
526
21
  max-width: 1280px;
527
22
  }
528
23
  }
529
24
  @media (min-width: 1536px) {
530
-
531
25
  .diff-tailwindcss-wrapper .container {
532
26
  max-width: 1536px;
533
27
  }
@@ -773,10 +267,10 @@ video {
773
267
  }
774
268
  .diff-tailwindcss-wrapper[data-theme="light"] .diff-style-root {
775
269
  --diff-border--: #dedede;
776
- --diff-add-content--: #e6ffec;
270
+ --diff-add-content--: #dafbe1;
777
271
  --diff-del-content--: #ffebe9;
778
- --diff-add-lineNumber--: #ccffd8;
779
- --diff-del-lineNumber--: #ffd7d5;
272
+ --diff-add-lineNumber--: #aceebb;
273
+ --diff-del-lineNumber--: #ffcecb;
780
274
  --diff-plain-content--: #ffffff;
781
275
  --diff-expand-content--: #fafafa;
782
276
  --diff-plain-lineNumber--: #fafafa;
@@ -784,10 +278,10 @@ video {
784
278
  --diff-plain-lineNumber-color--: #555555;
785
279
  --diff-expand-lineNumber-color--: #555555;
786
280
  --diff-hunk-content--: #ddf4ff;
787
- --diff-hunk-lineNumber--: #c7ecff;
281
+ --diff-hunk-lineNumber--: #b6e3ff;
788
282
  --diff-hunk-lineNumber-hover--: #0969da;
789
- --diff-add-content-highlight--: #abf2bc;
790
- --diff-del-content-highlight--: #ffb3ad;
283
+ --diff-add-content-highlight--: #aceebb;
284
+ --diff-del-content-highlight--: #ffcecb;
791
285
  --diff-add-widget--: #0969d2;
792
286
  --diff-add-widget-color--: #ffffff;
793
287
  --diff-empty-content--: #fafafa;
@@ -802,10 +296,10 @@ video {
802
296
  }
803
297
  .diff-tailwindcss-wrapper[data-theme="dark"] .diff-style-root {
804
298
  --diff-border--: #3d444d;
805
- --diff-add-content--: #14261f;
806
- --diff-del-content--: #311b1f;
807
- --diff-add-lineNumber--: #1f4429;
808
- --diff-del-lineNumber--: #552527;
299
+ --diff-add-content--: #18271f;
300
+ --diff-del-content--: #23191c;
301
+ --diff-add-lineNumber--: #284228;
302
+ --diff-del-lineNumber--: #4f2828;
809
303
  --diff-plain-content--: #0d1117;
810
304
  --diff-expand-content--: #161b22;
811
305
  --diff-plain-lineNumber--: #161b22;
@@ -813,10 +307,10 @@ video {
813
307
  --diff-plain-lineNumber-color--: #a0aaab;
814
308
  --diff-expand-lineNumber-color--: #a0aaab;
815
309
  --diff-hunk-content--: #131d2e;
816
- --diff-hunk-lineNumber--: #204274;
310
+ --diff-hunk-lineNumber--: #0c2d6b;
817
311
  --diff-hunk-lineNumber-hover--: #1f6feb;
818
- --diff-add-content-highlight--: #1f572d;
819
- --diff-del-content-highlight--: #80312f;
312
+ --diff-add-content-highlight--: #2f5732;
313
+ --diff-del-content-highlight--: #713431;
820
314
  --diff-add-widget--: #0969d2;
821
315
  --diff-add-widget-color--: #ffffff;
822
316
  --diff-empty-content--: #161b22;
@@ -1,5 +1,5 @@
1
1
  'use client';
2
- import { DiffLineType, getSyntaxDiffTemplate, getSyntaxLineTemplate, getPlainDiffTemplate, getPlainLineTemplate, SplitSide, checkDiffLineIncludeChange, composeLen, getSplitContentLines, getUnifiedContentLine, _cacheMap, DiffFile } from '@git-diff-view/core';
2
+ import { SplitSide, DiffLineType, getSyntaxDiffTemplate, getSyntaxLineTemplate, getPlainDiffTemplate, getPlainLineTemplate, checkDiffLineIncludeChange, composeLen, getSplitContentLines, getUnifiedContentLine, _cacheMap, DiffFile } from '@git-diff-view/core';
3
3
  export * from '@git-diff-view/core';
4
4
  export { SplitSide } from '@git-diff-view/core';
5
5
  import * as React from 'react';
@@ -297,7 +297,7 @@ const useTextWidth = ({ text, font, }) => {
297
297
  };
298
298
 
299
299
  const DiffSplitAddWidget = ({ side, className, lineNumber, onWidgetClick, onOpenAddWidget, }) => {
300
- return (React.createElement("div", { className: "diff-add-widget-wrapper invisible select-none transition-transform hover:scale-110 group-hover:visible" +
300
+ return (React.createElement("div", { "data-add-widget": SplitSide[side], className: "diff-add-widget-wrapper invisible select-none transition-transform hover:scale-110 group-hover:visible" +
301
301
  (className ? " " + className : ""), style: {
302
302
  width: `calc(var(${diffFontSizeName}) * 1.4)`,
303
303
  height: `calc(var(${diffFontSizeName}) * 1.4)`,
@@ -312,7 +312,7 @@ const DiffSplitAddWidget = ({ side, className, lineNumber, onWidgetClick, onOpen
312
312
  } }, "+")));
313
313
  };
314
314
  const DiffUnifiedAddWidget = ({ lineNumber, side, onWidgetClick, onOpenAddWidget, }) => {
315
- return (React.createElement("div", { className: "diff-add-widget-wrapper invisible absolute left-[100%] translate-x-[-50%] select-none transition-transform hover:scale-110 group-hover:visible", style: {
315
+ return (React.createElement("div", { "data-add-widget": SplitSide[side], className: "diff-add-widget-wrapper invisible absolute left-[100%] translate-x-[-50%] select-none transition-transform hover:scale-110 group-hover:visible", style: {
316
316
  width: `calc(var(${diffFontSizeName}) * 1.4)`,
317
317
  height: `calc(var(${diffFontSizeName}) * 1.4)`,
318
318
  top: `calc(var(${diffFontSizeName}) * 0.1)`,
@@ -766,8 +766,8 @@ const InternalDiffSplitHunkLineGitLab = ({ index, diffFile, side, lineNumber, })
766
766
  const expandEnabled = diffFile.getExpandEnabled();
767
767
  useSyncHeight({
768
768
  selector: `tr[data-line="${lineNumber}-hunk"]`,
769
- side: SplitSide[side],
770
- enable: true,
769
+ side: SplitSide[SplitSide.old],
770
+ enable: side === SplitSide.new,
771
771
  });
772
772
  const couldExpand = expandEnabled && currentHunk && currentHunk.splitInfo;
773
773
  const isExpandAll = currentHunk &&
@@ -1566,7 +1566,7 @@ const InternalDiffUnifiedExtendLine = ({ index, diffFile, lineNumber, enableWrap
1566
1566
  // TODO use css variable to get width
1567
1567
  const width = useDomWidth({
1568
1568
  selector: ".unified-diff-table-wrapper",
1569
- enable: typeof renderExtendLine === "function" && !enableWrap,
1569
+ enable: typeof renderExtendLine === "function",
1570
1570
  });
1571
1571
  if (!renderExtendLine)
1572
1572
  return null;
@@ -1669,7 +1669,7 @@ const InternalDiffUnifiedWidgetLine = ({ index, diffFile, lineNumber, enableWrap
1669
1669
  const renderWidgetLine = useDiffContext.useShallowStableSelector((s) => s.renderWidgetLine);
1670
1670
  const width = useDomWidth({
1671
1671
  selector: ".unified-diff-table-wrapper",
1672
- enable: typeof renderWidgetLine === "function" && !enableWrap,
1672
+ enable: typeof renderWidgetLine === "function",
1673
1673
  });
1674
1674
  if (!renderWidgetLine)
1675
1675
  return null;
@@ -1869,7 +1869,7 @@ const InternalDiffView = (props) => {
1869
1869
  }, [useDiffContext, wrapperRef]);
1870
1870
  const value = useMemo(() => ({ useDiffContext }), [useDiffContext]);
1871
1871
  return (React.createElement(DiffViewContext.Provider, { value: value },
1872
- React.createElement("div", { className: "diff-tailwindcss-wrapper", "data-component": "git-diff-view", "data-theme": diffFile._getTheme() || "light", "data-version": "0.0.34", "data-highlighter": diffFile._getHighlighterName(), ref: wrapperRef },
1872
+ React.createElement("div", { className: "diff-tailwindcss-wrapper", "data-component": "git-diff-view", "data-theme": diffFile._getTheme() || "light", "data-version": "0.0.36", "data-highlighter": diffFile._getHighlighterName(), ref: wrapperRef },
1873
1873
  React.createElement("div", { className: "diff-style-root", style: {
1874
1874
  // @ts-ignore
1875
1875
  [diffFontSizeName]: diffViewFontSize + "px",
@@ -1948,7 +1948,7 @@ const DiffViewWithRef = (props, ref) => {
1948
1948
  const InnerDiffView = forwardRef(DiffViewWithRef);
1949
1949
  InnerDiffView.displayName = "DiffView";
1950
1950
  const DiffView = InnerDiffView;
1951
- const version = "0.0.34";
1951
+ const version = "0.0.36";
1952
1952
 
1953
1953
  export { DiffModeEnum, DiffView, version };
1954
1954
  //# sourceMappingURL=index.mjs.map