110
110
111
111
●●options
112
112
113
- spec_date:2025 - 03 - 20
114
- trans_update:2025 - 03 - 30
113
+ spec_date:2025 - 04 - 10
114
+ trans_update:2025 - 04 - 17
115
115
source_checked:240321
116
116
page_state_key:*
117
117
original_url:https://wicg.github.io/sanitizer-api/
225
225
% B :-
226
226
% 準拠 ~ HTML :compliantHTML
227
227
% bool
228
+ % ~ commentや ~ data属性を許容するか :allowCommentsAndDataAttributes
228
229
229
230
●構文
230
231
@@ -1315,9 +1316,9 @@ <h3 title="SetHTML options and the configuration object.">2.2. `SetHTML^I ~optio
1315
1316
【この段は、この訳による補完。】
1316
1317
</ li >
1317
1318
< li >
1318
- %妥当か ~LET `環境設定を設定する$( コレ, %configuration, 【ここに与えるべき引数が`指定されていない@https://github.com/WICG/sanitizer-api/issues/273$】 )
1319
+ %妥当か ~LET `環境設定を設定する$( コレ, %configuration, ~T )
1319
1320
◎
1320
- Let valid be the return value of setting configuration on this.
1321
+ Let valid be the return value of set a configuration with configuration and true on this.
1321
1322
</ li >
1322
1323
< li >
1323
1324
~IF[
@@ -1601,9 +1602,9 @@ <h2 title="Algorithms">3. ~algo</h2>
1601
1602
• Let sanitizer be a new Sanitizer instance.
1602
1603
</ li >
1603
1604
< li >
1604
- %妥当か ~LET `環境設定を設定する$( %無毒化器, %無毒化器~指定, %安全か )
1605
+ %妥当か ~LET `環境設定を設定する$( %無毒化器, %無毒化器~指定, ~IS[ %安全か ~EQ ~F ] )
1605
1606
◎
1606
- • Let setConfigurationResult be the result of set a configuration with sanitizerSpec and safe on sanitizer.
1607
+ • Let setConfigurationResult be the result of set a configuration with sanitizerSpec and not safe on sanitizer.
1607
1608
</ li >
1608
1609
< li >
1609
1610
~IF[
@@ -2457,18 +2458,18 @@ <h3 title="Configuration Processing">3.2. 環境設定の処理-法</h3>
2457
2458
`環境設定を設定する@
2458
2459
~algoは、
2459
2460
所与の
2460
- ( `Sanitizer$I %無毒化器, `辞書$ %~source環境設定, `真偽値$ %安全か )
2461
+ ( `Sanitizer$I %無毒化器, `辞書$ %~source環境設定, `真偽値$ %~commentや~data属性を許容するか )
2461
2462
に対し:
2462
2463
◎
2463
- To set a configuration, given a dictionary configuration, a boolean safe , and a Sanitizer sanitizer:
2464
+ To set a configuration, given a dictionary configuration, a boolean allowCommentsAndDataAttributes , and a Sanitizer sanitizer:
2464
2465
</ p >
2465
2466
< ol >
2466
2467
< li >
2467
2468
%全部的な環境設定 ~LET %~source環境設定 の複製
2468
2469
</ li >
2469
2470
< li >
2470
2471
< p >
2471
- `環境設定の欠落~memberを初期化する$( %全部的な環境設定, %安全か )
2472
+ `環境設定の欠落~memberを初期化する$( %全部的な環境設定, %~commentや~data属性を許容するか )
2472
2473
</ p >
2473
2474
2474
2475
< p class ="trans-note "> 【
@@ -2481,17 +2482,9 @@ <h3 title="Configuration Processing">3.2. 環境設定の処理-法</h3>
2481
2482
】</ p >
2482
2483
</ li >
2483
2484
< li >
2484
- < p >
2485
2485
%環境設定 ~LET %無毒化器 の`環境設定$
2486
- </ p >
2487
-
2488
- < p class ="trans-note "> 【
2489
- この段は、
2490
- この訳による補完。
2491
- 以下で呼出される各~algoにおいて %環境設定 ではなく %無毒化器 を渡しているが、
2492
- 引数の型が合致していないので。
2493
- 】</ p >
2494
- </ li >
2486
+ ◎
2487
+ ↓</ li >
2495
2488
< li >
2496
2489
%全部的な環境設定[ "`elements$mb" ] を成す
2497
2490
~EACH( %要素 )
@@ -2500,7 +2493,7 @@ <h3 title="Configuration Processing">3.2. 環境設定の処理-法</h3>
2500
2493
`要素を許容するようにする$( %環境設定, %要素 )
2501
2494
◎
2502
2495
For each element of configuration["elements"] do:
2503
- • Call allow an element with element and sanitizer.
2496
+ • Call allow an element with element and sanitizer’s configuration .
2504
2497
</ li >
2505
2498
< li >
2506
2499
%全部的な環境設定[ "`removeElements$mb" ] を成す
@@ -2510,7 +2503,7 @@ <h3 title="Configuration Processing">3.2. 環境設定の処理-法</h3>
2510
2503
`要素を除去するようにする$( %環境設定, %要素 )
2511
2504
◎
2512
2505
For each element of configuration["removeElements"] do:
2513
- • Call remove an element with element and sanitizer.
2506
+ • Call remove an element with element and sanitizer’s configuration .
2514
2507
</ li >
2515
2508
< li >
2516
2509
%全部的な環境設定[ "`replaceWithChildrenElements$mb" ] を成す
@@ -2520,7 +2513,7 @@ <h3 title="Configuration Processing">3.2. 環境設定の処理-法</h3>
2520
2513
`要素をその子~群で置換するようにする$( %環境設定, %要素 )
2521
2514
◎
2522
2515
For each element of configuration["replaceWithChildrenElements"] do:
2523
- • Call replace an element with its children with element and sanitizer.
2516
+ • Call replace an element with its children with element and sanitizer’s configuration .
2524
2517
</ li >
2525
2518
< li >
2526
2519
%全部的な環境設定[ "`attributes$mb" ] を成す
@@ -2530,7 +2523,7 @@ <h3 title="Configuration Processing">3.2. 環境設定の処理-法</h3>
2530
2523
`属性を許容するようにする$( %環境設定, %属性 )
2531
2524
◎
2532
2525
For each attribute of configuration["attributes"] do:
2533
- • Call allow an attribute with attribute and sanitizer.
2526
+ • Call allow an attribute with attribute and sanitizer’s configuration .
2534
2527
</ li >
2535
2528
< li >
2536
2529
%全部的な環境設定[ "`removeAttributes$mb" ] を成す
@@ -2540,21 +2533,21 @@ <h3 title="Configuration Processing">3.2. 環境設定の処理-法</h3>
2540
2533
`属性を除去するようにする$( %環境設定, %属性 )
2541
2534
◎
2542
2535
For each attribute of configuration["removeAttributes"] do:
2543
- • Call remove an attribute with attribute and sanitizer.
2536
+ • Call remove an attribute with attribute and sanitizer’s configuration .
2544
2537
</ li >
2545
2538
< li >
2546
2539
`~commentを許容するか否か設定する$( %環境設定, %全部的な環境設定[ "`comments$mb" ] )
2547
2540
◎
2548
2541
If configuration["comments"] exists:
2549
- • Then call set comments with configuration["comments"] and sanitizer.
2550
- • Otherwise call set comments with not safe and sanitizer.
2542
+ • Then call set comments with configuration["comments"] and sanitizer’s configuration .
2543
+ • Otherwise call set comments with allowCommentsAndDataAttributes and sanitizer’s configuration .
2551
2544
</ li >
2552
2545
< li >
2553
2546
`~data属性を許容するか否か設定する$( %環境設定, %全部的な環境設定[ "`dataAttributes$mb" ] )
2554
2547
◎
2555
2548
If configuration["dataAttributes"] exists:
2556
- • Then call set data attributes with configuration["dataAttributes"] and sanitizer.
2557
- • Otherwise call set data attributes with not safe and sanitizer.
2549
+ • Then call set data attributes with configuration["dataAttributes"] and sanitizer’s configuration .
2550
+ • Otherwise call set data attributes with allowCommentsAndDataAttributes and sanitizer’s configuration .
2558
2551
</ li >
2559
2552
< li >
2560
2553
< p >
@@ -2586,11 +2579,11 @@ <h3 title="Configuration Processing">3.2. 環境設定の処理-法</h3>
2586
2579
</ ol >
2587
2580
◎
2588
2581
Return whether all of the following are true:
2589
- • size of configuration["elements"] equals size of this ’s configuration["elements"].
2590
- • size of configuration["removeElements"] equals size of this ’s configuration["removeElements"].
2591
- • size of configuration["replaceWithChildrenElements"] equals size of this ’s configuration["replaceWithChildrenElements"].
2592
- • size of configuration["attributes"] equals size of this ’s configuration["attributes"].
2593
- • size of configuration["removeAttributes"] equals size of this ’s configuration["removeAttributes"].
2582
+ • size of configuration["elements"] equals size of sanitizer ’s configuration["elements"].
2583
+ • size of configuration["removeElements"] equals size of sanitizer ’s configuration["removeElements"].
2584
+ • size of configuration["replaceWithChildrenElements"] equals size of sanitizer ’s configuration["replaceWithChildrenElements"].
2585
+ • size of configuration["attributes"] equals size of sanitizer ’s configuration["attributes"].
2586
+ • size of configuration["removeAttributes"] equals size of sanitizer ’s configuration["removeAttributes"].
2594
2587
</ li >
2595
2588
< li >
2596
2589
< p >
@@ -2691,7 +2684,7 @@ <h3 title="Configuration Processing">3.2. 環境設定の処理-法</h3>
2691
2684
`環境設定の欠落~memberを初期化する@
2692
2685
~algoは、
2693
2686
所与の
2694
- ( `SanitizerConfig$I %環境設定, `真偽値$ %安全か )
2687
+ ( `SanitizerConfig$I %環境設定, `真偽値$ %~commentや~data属性を許容するか )
2695
2688
に対し:
2696
2689
</ p >
2697
2690
< ol >
@@ -2733,9 +2726,7 @@ <h3 title="Configuration Processing">3.2. 環境設定の処理-法</h3>
2733
2726
%環境設定[ %~key ] ~EQ ε
2734
2727
]
2735
2728
⇒
2736
- %環境設定[ %~key ] ~SET ~IS[
2737
- %安全か ~EQ ~F
2738
- ]
2729
+ %環境設定[ %~key ] ~SET %~commentや~data属性を許容するか
2739
2730
</ li >
2740
2731
</ ol >
2741
2732
@@ -3383,22 +3374,12 @@ <h3 title="Builtins">3.4. 組込みのもの</h3>
3383
3374
{
3384
3375
"name": "dfn",
3385
3376
"namespace": %HTMLNS,
3386
- "attributes": [
3387
- {
3388
- "name": "title",
3389
- "namespace": null
3390
- }
3391
- ]
3377
+ "attributes": []
3392
3378
},
3393
3379
{
3394
3380
"name": "abbr",
3395
3381
"namespace": %HTMLNS,
3396
- "attributes": [
3397
- {
3398
- "name": "title",
3399
- "namespace": null
3400
- }
3401
- ]
3382
+ "attributes": []
3402
3383
},
3403
3384
{
3404
3385
"name": "ruby",
@@ -3488,22 +3469,12 @@ <h3 title="Builtins">3.4. 組込みのもの</h3>
3488
3469
{
3489
3470
"name": "bdi",
3490
3471
"namespace": %HTMLNS,
3491
- "attributes": [
3492
- {
3493
- "name": "dir",
3494
- "namespace": null
3495
- }
3496
- ]
3472
+ "attributes": []
3497
3473
},
3498
3474
{
3499
3475
"name": "bdo",
3500
3476
"namespace": %HTMLNS,
3501
- "attributes": [
3502
- {
3503
- "name": "dir",
3504
- "namespace": null
3505
- }
3506
- ]
3477
+ "attributes": []
3507
3478
},
3508
3479
{
3509
3480
"name": "span",
@@ -3919,6 +3890,8 @@ <h3 title="Builtins">3.4. 組込みのもの</h3>
3919
3890
"namespace": null
3920
3891
}
3921
3892
]
3893
+ "comments": false,
3894
+ "dataAttributes": false
3922
3895
}
3923
3896
</ pre >
3924
3897
0 commit comments