Commit 8bcaa92
authored
feat[plugin][smartling]: ENG-9736 visual context upload, exclude blocks, edit/add/delete string instructions (#4218)
## Description
This PR has 3 new features
1. Uploading Visual context to smartling. This PR has the settings part
of it
2. Ability to exclude/include blocks from translations into Smartling
3. Add/Edit/Delete string instructions to blocks
**Loom**
For features 1 and 2 ->
https://www.loom.com/share/d6d8c880667c4453b43c7c8b7af4de0a
For feature 3 ->
https://www.loom.com/share/060f9094fc3c4865972cef2f4624e1d7
<!-- CURSOR_SUMMARY -->
---
> [!NOTE]
> - **Smartling plugin**
> - New `enableVisualContextCapture` setting in plugin settings.
> - Context menu expanded: exclude/include any block from future
translations; new actions to `Add/Edit/Delete` per-string `instructions`
stored on `meta`.
> - Minor job actions logic refinements; version bumped and
`@builder.io/utils` dependency updated to `1.1.29`.
>
> - **Utils (`translation-helpers.ts`)**
> - Translation extraction/application now respects nested
`meta.excludeFromTranslation` via depth tracking; skips all descendant
nodes within excluded blocks.
> - Applies exclusion uniformly to `Text`, `Core:Button`, `Symbol`, and
custom components with `localizedTextInputs`.
> - Snapshots updated to reflect button text handling and additional
fields; package version bumped to `1.1.29`.
>
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
91b1cb6. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->1 parent 5f25224 commit 8bcaa92
File tree
7 files changed
+175
-49
lines changed- packages/utils
- src
- __snapshots__
- plugins/smartling
- src
7 files changed
+175
-49
lines changedSome generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
Lines changed: 33 additions & 25 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
322 | 322 | | |
323 | 323 | | |
324 | 324 | | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
325 | 350 | | |
326 | 351 | | |
327 | 352 | | |
| |||
360 | 385 | | |
361 | 386 | | |
362 | 387 | | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
363 | 396 | | |
364 | 397 | | |
365 | 398 | | |
| |||
386 | 419 | | |
387 | 420 | | |
388 | 421 | | |
389 | | - | |
390 | | - | |
391 | | - | |
392 | | - | |
393 | | - | |
394 | | - | |
395 | | - | |
396 | | - | |
397 | | - | |
398 | | - | |
399 | | - | |
400 | | - | |
401 | | - | |
402 | | - | |
403 | | - | |
404 | | - | |
405 | | - | |
406 | | - | |
407 | | - | |
408 | | - | |
409 | | - | |
410 | | - | |
411 | | - | |
412 | | - | |
413 | | - | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
220 | 220 | | |
221 | 221 | | |
222 | 222 | | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
223 | 226 | | |
224 | | - | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
225 | 244 | | |
226 | 245 | | |
227 | 246 | | |
| |||
238 | 257 | | |
239 | 258 | | |
240 | 259 | | |
241 | | - | |
| 260 | + | |
242 | 261 | | |
243 | 262 | | |
244 | 263 | | |
| |||
249 | 268 | | |
250 | 269 | | |
251 | 270 | | |
252 | | - | |
| 271 | + | |
253 | 272 | | |
254 | 273 | | |
255 | 274 | | |
| |||
264 | 283 | | |
265 | 284 | | |
266 | 285 | | |
267 | | - | |
| 286 | + | |
268 | 287 | | |
269 | 288 | | |
270 | 289 | | |
| |||
316 | 335 | | |
317 | 336 | | |
318 | 337 | | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
319 | 341 | | |
320 | | - | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
321 | 359 | | |
322 | 360 | | |
323 | 361 | | |
| |||
368 | 406 | | |
369 | 407 | | |
370 | 408 | | |
371 | | - | |
| 409 | + | |
372 | 410 | | |
373 | 411 | | |
374 | 412 | | |
| |||
405 | 443 | | |
406 | 444 | | |
407 | 445 | | |
408 | | - | |
| 446 | + | |
409 | 447 | | |
410 | 448 | | |
411 | 449 | | |
| |||
440 | 478 | | |
441 | 479 | | |
442 | 480 | | |
443 | | - | |
| 481 | + | |
444 | 482 | | |
445 | 483 | | |
446 | 484 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
125 | 125 | | |
126 | 126 | | |
127 | 127 | | |
128 | | - | |
| 128 | + | |
129 | 129 | | |
130 | 130 | | |
131 | 131 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
163 | 163 | | |
164 | 164 | | |
165 | 165 | | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
166 | 174 | | |
167 | 175 | | |
168 | 176 | | |
| |||
460 | 468 | | |
461 | 469 | | |
462 | 470 | | |
463 | | - | |
| 471 | + | |
464 | 472 | | |
465 | 473 | | |
466 | 474 | | |
| |||
476 | 484 | | |
477 | 485 | | |
478 | 486 | | |
479 | | - | |
| 487 | + | |
480 | 488 | | |
481 | 489 | | |
482 | 490 | | |
483 | 491 | | |
484 | 492 | | |
485 | 493 | | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
| 554 | + | |
| 555 | + | |
| 556 | + | |
| 557 | + | |
| 558 | + | |
| 559 | + | |
| 560 | + | |
| 561 | + | |
| 562 | + | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
486 | 566 | | |
487 | 567 | | |
488 | 568 | | |
| |||
0 commit comments