Änderungen von Dokument Get Started
Zuletzt geändert von Veronika Kocher am Freitag, 04 Sep. 2026 14:45
Von Version 2.9
bearbeitet von Veronika Kocher
am Donnerstag, 03 Sep. 2026 14:15
am Donnerstag, 03 Sep. 2026 14:15
Änderungskommentar:
Es gibt keinen Kommentar für diese Version
Auf Version 2.5
bearbeitet von Veronika Kocher
am Donnerstag, 03 Sep. 2026 9:18
am Donnerstag, 03 Sep. 2026 9:18
Änderungskommentar:
Es gibt keinen Kommentar für diese Version
Zusammenfassung
-
Seiteneigenschaften (1 geändert, 0 hinzugefügt, 0 gelöscht)
Details
- Seiteneigenschaften
-
- Inhalt
-
... ... @@ -388,132 +388,21 @@ 388 388 {{/html}} 389 389 390 390 {{html clean="false"}} 391 -<!-- SN_SERVICE_NAVIGATOR_MASTER_STYLE_START --> 392 - 393 -<style data-sn-service-navigator-master="1"> 394 -/* ========================================================= 395 - MASTER TYPOGRAPHY 396 - ========================================================= */ 397 -#xwikicontent h1, 398 -#xwikicontent h2, 399 -#xwikicontent h3, 400 -#xwikicontent h4, 401 -#xwikicontent h5, 402 -#xwikicontent h6, 403 -#xwikicontent .box-title, 404 -#xwikicontent [role="heading"], 405 -#xwikicontent h1 a, 406 -#xwikicontent h2 a, 407 -#xwikicontent h3 a, 408 -#xwikicontent h4 a, 409 -#xwikicontent h5 a, 410 -#xwikicontent h6 a, 411 -#xwikicontent .box-title a, 412 -#xwikicontent [role="heading"] a{ 413 - text-align:left!important; 414 - text-justify:auto!important; 415 - word-spacing:normal!important; 391 +<!-- SN_HORIZONTAL_BOX_HARMONIZER_START --> 392 +<style data-sn-horizontal-box-harmonizer="1"> 393 +[data-sn-equal-height-managed="1"]{box-sizing:border-box} 394 +@media(max-width:767px){ 395 + [data-sn-equal-height-managed="1"]{min-height:0!important} 416 416 } 417 - 418 -/* ========================================================= 419 - COMING SOON / IN VORBEREITUNG 420 - ========================================================= */ 421 -.sn-coming-soon-badge{ 422 - display:inline-block; 423 - vertical-align:middle; 424 - margin-left:10px; 425 - padding:4px 8px; 426 - border-radius:14px; 427 - border:1px solid #efd9cc; 428 - background:#fff4ee; 429 - color:#8a4d36; 430 - font-size:11px; 431 - font-weight:700; 432 - letter-spacing:.055em; 433 - line-height:1.2; 434 - white-space:nowrap; 435 -} 436 - 437 -/* ========================================================= 438 - NATIVE / DETAIL CALLOUT GEOMETRY 439 - Preserve existing backgrounds. 440 - ========================================================= */ 441 -#xwikicontent .arsn-info, 442 -#xwikicontent .dmp-info, 443 -#xwikicontent .ido-info, 444 -#xwikicontent .pp-info, 445 -#xwikicontent .infomessage{ 446 - box-sizing:border-box!important; 447 - border-left:4px solid #21b6d7!important; 448 - border-radius:8px; 449 - text-align:left!important; 450 - word-spacing:normal!important; 451 -} 452 - 453 -#xwikicontent .arsn-warn, 454 -#xwikicontent .dmp-warn, 455 -#xwikicontent .ido-warn, 456 -#xwikicontent .pp-warn, 457 -#xwikicontent .warn, 458 -#xwikicontent .warning, 459 -#xwikicontent .warningmessage, 460 -#xwikicontent .errormessage{ 461 - box-sizing:border-box!important; 462 - border-left:4px solid #e94b13!important; 463 - border-radius:8px; 464 - text-align:left!important; 465 - word-spacing:normal!important; 466 -} 467 - 468 -[data-sn-master-equal-height], 469 -[data-sn-master-first-row]{ 470 - box-sizing:border-box; 471 -} 472 - 473 -/* ========================================================= 474 - FULL-WIDTH THREE-LINE NUMBER / TITLE / SUBTITLE BLOCKS 475 - ========================================================= */ 476 -#xwikicontent .arsn-area-label[data-sn-three-line="1"]{ 477 - display:grid!important; 478 - grid-template-columns:minmax(0,1fr)!important; 479 - grid-auto-rows:auto!important; 480 - width:100%!important; 481 - max-width:none!important; 482 - box-sizing:border-box!important; 483 - justify-items:start!important; 484 - align-items:start!important; 485 - gap:2px!important; 486 - text-align:left!important; 487 - text-align-last:left!important; 488 - text-justify:auto!important; 489 - word-spacing:normal!important; 490 - white-space:normal!important; 491 -} 492 -#xwikicontent .arsn-area-label[data-sn-three-line="1"] > .arsn-area-number, 493 -#xwikicontent .arsn-area-label[data-sn-three-line="1"] > .sn-area-label-title, 494 -#xwikicontent .arsn-area-label[data-sn-three-line="1"] > .arsn-area-action{ 495 - display:block!important; 496 - width:100%!important; 497 - margin:0!important; 498 - text-align:left!important; 499 - text-align-last:left!important; 500 - text-justify:auto!important; 501 - word-spacing:normal!important; 502 - white-space:normal!important; 503 -} 504 504 </style> 505 - 506 -<script data-sn-service-navigator-master="1"> 398 +<script data-sn-horizontal-box-harmonizer="1"> 507 507 (function(){ 508 508 "use strict"; 509 509 510 - var PAGE_KIND="detail"; 511 - var PLACEHOLDER=false; 512 - var PLACEHOLDER_LABEL="IN VORBEREITUNG"; 513 - 514 514 var MOBILE_MAX=767; 515 - var ROW_TOLERANCE=6; 516 - var RESIZE_DEBOUNCE=220; 403 + var ROW_TOLERANCE=4; 404 + var MIN_W=150; 405 + var MIN_H=36; 517 517 518 518 var root= 519 519 document.getElementById("xwikicontent")|| ... ... @@ -523,1268 +523,212 @@ 523 523 524 524 if(!root)return; 525 525 526 - var managedHeight=new Set(); 527 - var managedMargin=new Set(); 528 - var originalHeight=new WeakMap(); 529 - var originalMargin=new WeakMap(); 415 + var managed=new Set(); 416 + var raf=0; 530 530 531 - var resizeTimer=0; 532 - var running=false; 533 - 534 - var THEMES=[ 535 - { 536 - name:"BLUE", 537 - accent:"#21b6d7", 538 - bg:"#eaf7fb", 539 - text:"#315d68", 540 - labels:[ 541 - "HIER STARTEN", 542 - "ENTSCHEIDEN", 543 - "ÜBERPRÜFEN & ANPASSEN", 544 - "START HERE", 545 - "DECIDE", 546 - "REVIEW & ADAPT" 547 - ] 548 - }, 549 - { 550 - name:"RED", 551 - accent:"#e94b13", 552 - bg:"#fff1ec", 553 - text:"#8a4d36", 554 - labels:[ 555 - "PLANEN & ORGANISIEREN", 556 - "ORGANISIEREN & DOKUMENTIEREN", 557 - "PUBLIZIEREN & PRÄSENTIEREN", 558 - "PLAN & ORGANISE", 559 - "PLAN & ORGANIZE", 560 - "ORGANISE & DOCUMENT", 561 - "ORGANIZE & DOCUMENT", 562 - "PUBLISH & PRESENT" 563 - ] 564 - }, 565 - { 566 - name:"YELLOW", 567 - accent:"#f0aa00", 568 - bg:"#fff8e7", 569 - text:"#785b17", 570 - labels:[ 571 - "SCHÜTZEN & KLÄREN", 572 - "STANDARDISIEREN & IDENTIFIZIEREN", 573 - "ÖFFNEN, NACHNUTZEN & AUFFINDBAR MACHEN", 574 - "PROTECT & CLARIFY", 575 - "STANDARDISE & IDENTIFY", 576 - "STANDARDIZE & IDENTIFY", 577 - "OPEN, REUSE & MAKE FINDABLE" 578 - ] 579 - }, 580 - { 581 - name:"GREEN", 582 - accent:"#38b76a", 583 - bg:"#edf9f1", 584 - text:"#3f7451", 585 - labels:[ 586 - "INFRASTRUKTUR EINRICHTEN", 587 - "INFRASTRUKTUR & ZUSAMMENARBEIT EINRICHTEN", 588 - "SPEICHERN & ZUGRIFF STEUERN", 589 - "REPOSITORIUM, ERHALTEN & ÜBERGEBEN", 590 - "SET UP INFRASTRUCTURE", 591 - "SET UP INFRASTRUCTURE & COLLABORATION", 592 - "STORE & CONTROL ACCESS", 593 - "REPOSITORY, PRESERVE & HAND OVER" 594 - ] 595 - } 596 - ]; 597 - 598 - function num(value){ 599 - var n=parseFloat(value); 418 + function num(v){ 419 + var n=parseFloat(v); 600 600 return Number.isFinite(n)?n:0; 601 601 } 602 602 603 - function norm(value){ 604 - return String(value||"") 605 - .replace(/\s+/g," ") 606 - .trim() 607 - .toUpperCase(); 608 - } 609 - 610 610 function visible(el){ 611 611 if(!el||el.nodeType!==1)return false; 612 - 613 - var style=getComputedStyle(el); 614 - var rect=el.getBoundingClientRect(); 615 - 616 - return ( 617 - style.display!=="none"&& 618 - style.visibility!=="hidden"&& 619 - rect.width>20&& 620 - rect.height>4 621 - ); 425 + var s=getComputedStyle(el); 426 + if(s.display==="none"||s.visibility==="hidden"||Number(s.opacity)===0)return false; 427 + var r=el.getBoundingClientRect(); 428 + return r.width>=MIN_W&&r.height>=MIN_H; 622 622 } 623 623 624 - function saveStyle(el,map,property){ 625 - if(map.has(el))return; 626 - 627 - map.set(el,{ 628 - value:el.style.getPropertyValue(property), 629 - priority:el.style.getPropertyPriority(property) 630 - }); 631 - } 632 - 633 - function restoreStyle(el,map,property){ 634 - var original=map.get(el); 635 - 636 - if(original&&original.value){ 637 - el.style.setProperty( 638 - property, 639 - original.value, 640 - original.priority||"" 641 - ); 642 - }else{ 643 - el.style.removeProperty(property); 644 - } 645 - } 646 - 647 - function resetRuntime(){ 648 - managedHeight.forEach(function(el){ 649 - restoreStyle( 650 - el, 651 - originalHeight, 652 - "min-height" 653 - ); 654 - el.removeAttribute( 655 - "data-sn-master-equal-height" 656 - ); 657 - }); 658 - 659 - managedMargin.forEach(function(el){ 660 - restoreStyle( 661 - el, 662 - originalMargin, 663 - "margin-top" 664 - ); 665 - el.removeAttribute( 666 - "data-sn-master-first-row" 667 - ); 668 - }); 669 - 670 - managedHeight.clear(); 671 - managedMargin.clear(); 672 - } 673 - 674 - function themeFor(text){ 675 - var value=norm(text); 676 - 677 - for(var i=0;i<THEMES.length;i++){ 678 - for(var j=0;j<THEMES[i].labels.length;j++){ 679 - var label=THEMES[i].labels[j]; 680 - 681 - if( 682 - value===label|| 683 - value.indexOf(label+" ")===0|| 684 - value.indexOf(label+" -")===0|| 685 - value.indexOf(label+" ·")===0 686 - ){ 687 - return THEMES[i]; 688 - } 689 - } 690 - } 691 - 692 - return null; 693 - } 694 - 695 - /* ======================================================= 696 - BORDERLESS FILLED RED/ORANGE CTA BUTTONS 697 - ======================================================= */ 698 - 699 - function colourDistance(a,b){ 700 - return Math.sqrt( 701 - Math.pow(a[0]-b[0],2)+ 702 - Math.pow(a[1]-b[1],2)+ 703 - Math.pow(a[2]-b[2],2) 431 + function excluded(el){ 432 + return !el.matches||el.matches( 433 + "button,input,select,textarea,option,label,img,svg,canvas,table,thead,tbody,tfoot,tr,td,th,summary,script,style,noscript,template,.btn,.chip,[role=button]" 704 704 ); 705 705 } 706 706 707 - function makeFilledRedOrangeCTAsBorderless(){ 708 - var RED_ORANGE=[233,75,19]; 709 - 710 - Array.from( 711 - root.querySelectorAll( 712 - 'a,button,[role="button"],input[type="submit"],input[type="button"]' 713 - ) 714 - ).forEach(function(el){ 715 - if(!visible(el))return; 716 - 717 - var style=getComputedStyle(el); 718 - var rgb=parseRGB(style.backgroundColor); 719 - 720 - if(!rgb)return; 721 - 722 - if( 723 - colourDistance( 724 - rgb, 725 - RED_ORANGE 726 - )>55 727 - ){ 728 - return; 729 - } 730 - 731 - var rect=el.getBoundingClientRect(); 732 - 733 - if( 734 - rect.width<80|| 735 - rect.height<24 736 - ){ 737 - return; 738 - } 739 - 740 - el.style.setProperty( 741 - "border", 742 - "none", 743 - "important" 744 - ); 745 - 746 - el.style.setProperty( 747 - "border-left", 748 - "none", 749 - "important" 750 - ); 751 - 752 - el.style.setProperty( 753 - "border-top", 754 - "none", 755 - "important" 756 - ); 757 - 758 - el.style.setProperty( 759 - "border-right", 760 - "none", 761 - "important" 762 - ); 763 - 764 - el.style.setProperty( 765 - "border-bottom", 766 - "none", 767 - "important" 768 - ); 769 - 770 - el.style.setProperty( 771 - "box-shadow", 772 - "none", 773 - "important" 774 - ); 775 - }); 437 + function namedLikeBox(el){ 438 + var c=typeof el.className==="string"?el.className:""; 439 + return /(^|[\s_-])(box|card|tile|panel|role|check|service|source|call|area|detail|resource|topic|warn|info)([\s_-]|$)/i.test(c); 776 776 } 777 777 778 - /* ======================================================= 779 - FULL-WIDTH THREE-LINE AREA LABELS 780 - ======================================================= */ 781 - 782 - function compactText(value){ 783 - return String(value||"") 784 - .replace(/\s+/g," ") 785 - .trim(); 786 - } 787 - 788 - function makeThreeLineAreaLabels(){ 789 - Array.from( 790 - root.querySelectorAll( 791 - ".arsn-area-label" 792 - ) 793 - ).forEach(function(label){ 794 - if( 795 - label.getAttribute( 796 - "data-sn-three-line" 797 - )==="1" 798 - ){ 799 - return; 800 - } 801 - 802 - var number= 803 - label.querySelector( 804 - ":scope > .arsn-area-number" 805 - ); 806 - 807 - var action= 808 - label.querySelector( 809 - ":scope > .arsn-area-action" 810 - ); 811 - 812 - if( 813 - !number|| 814 - !action 815 - ){ 816 - return; 817 - } 818 - 819 - var clone= 820 - label.cloneNode(true); 821 - 822 - var cloneNumber= 823 - clone.querySelector( 824 - ":scope > .arsn-area-number" 825 - ); 826 - 827 - var cloneAction= 828 - clone.querySelector( 829 - ":scope > .arsn-area-action" 830 - ); 831 - 832 - if(cloneNumber){ 833 - cloneNumber.remove(); 834 - } 835 - 836 - if(cloneAction){ 837 - cloneAction.remove(); 838 - } 839 - 840 - var titleText= 841 - compactText( 842 - clone.textContent 843 - ); 844 - 845 - if(!titleText){ 846 - return; 847 - } 848 - 849 - var numberNode= 850 - number.cloneNode(true); 851 - 852 - var actionNode= 853 - action.cloneNode(true); 854 - 855 - var titleNode= 856 - document.createElement( 857 - "span" 858 - ); 859 - 860 - titleNode.className= 861 - "sn-area-label-title"; 862 - 863 - titleNode.textContent= 864 - titleText; 865 - 866 - while(label.firstChild){ 867 - label.removeChild( 868 - label.firstChild 869 - ); 870 - } 871 - 872 - label.appendChild( 873 - numberNode 874 - ); 875 - 876 - label.appendChild( 877 - titleNode 878 - ); 879 - 880 - label.appendChild( 881 - actionNode 882 - ); 883 - 884 - label.setAttribute( 885 - "data-sn-three-line", 886 - "1" 887 - ); 888 - 889 - var head= 890 - label.closest( 891 - ".arsn-area-head" 892 - ); 893 - 894 - if(head){ 895 - head.style.setProperty( 896 - "width", 897 - "100%", 898 - "important" 899 - ); 900 - 901 - head.style.setProperty( 902 - "max-width", 903 - "100%", 904 - "important" 905 - ); 906 - 907 - head.style.setProperty( 908 - "box-sizing", 909 - "border-box", 910 - "important" 911 - ); 912 - } 913 - }); 914 - } 915 - 916 - /* ======================================================= 917 - PLACEHOLDER BADGE 918 - ======================================================= */ 919 - 920 - function applyPlaceholderBadge(){ 921 - if(!PLACEHOLDER)return; 922 - 923 - if( 924 - document.querySelector( 925 - ".sn-coming-soon-badge" 926 - ) 927 - ){ 928 - return; 929 - } 930 - 931 - var title= 932 - document.querySelector( 933 - "#document-title" 934 - )|| 935 - document.querySelector( 936 - "h1" 937 - ); 938 - 939 - if(!title)return; 940 - 941 - var badge= 942 - document.createElement( 943 - "span" 944 - ); 945 - 946 - badge.className= 947 - "sn-coming-soon-badge"; 948 - 949 - badge.textContent= 950 - PLACEHOLDER_LABEL; 951 - 952 - badge.setAttribute( 953 - "aria-label", 954 - PLACEHOLDER_LABEL 442 + function boxLike(el){ 443 + if(!visible(el)||excluded(el))return false; 444 + var s=getComputedStyle(el); 445 + var r=el.getBoundingClientRect(); 446 + var border= 447 + num(s.borderTopWidth)+num(s.borderRightWidth)+ 448 + num(s.borderBottomWidth)+num(s.borderLeftWidth); 449 + var radius=Math.max( 450 + num(s.borderTopLeftRadius),num(s.borderTopRightRadius), 451 + num(s.borderBottomLeftRadius),num(s.borderBottomRightRadius) 955 955 ); 956 - 957 - title.appendChild( 958 - badge 959 - ); 453 + var bg=s.backgroundColor&&s.backgroundColor!=="rgba(0, 0, 0, 0)"&&s.backgroundColor!=="transparent"; 454 + var shadow=s.boxShadow&&s.boxShadow!=="none"; 455 + return namedLikeBox(el)||border>=1||(bg&&radius>=3)||(shadow&&r.width>=180); 960 960 } 961 961 962 - /*=======================================================963 - DETAIL PAGE OWN-ACCENT PROPAGATION964 - ======================================================= */458 + function pickTarget(child){ 459 + if(!visible(child))return null; 460 + if(boxLike(child))return child; 965 965 966 - function parseRGB(value){ 967 - var match=String(value||"").match( 968 - /rgba?\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)/i 969 - ); 970 - 971 - if(!match)return null; 972 - 973 - return [ 974 - Number(match[1]), 975 - Number(match[2]), 976 - Number(match[3]) 977 - ]; 978 - } 979 - 980 - function distance(a,b){ 981 - return Math.sqrt( 982 - Math.pow(a[0]-b[0],2)+ 983 - Math.pow(a[1]-b[1],2)+ 984 - Math.pow(a[2]-b[2],2) 985 - ); 986 - } 987 - 988 - function paletteMatch(cssColor){ 989 - var rgb=parseRGB(cssColor); 990 - 991 - if(!rgb)return null; 992 - 993 - var palette=[ 994 - {hex:"#21b6d7",rgb:[33,182,215]}, 995 - {hex:"#e94b13",rgb:[233,75,19]}, 996 - {hex:"#f0aa00",rgb:[240,170,0]}, 997 - {hex:"#38b76a",rgb:[56,183,106]} 998 - ]; 999 - 1000 - var best=null; 1001 - var bestDistance=Infinity; 1002 - 1003 - palette.forEach(function(item){ 1004 - var d=distance(rgb,item.rgb); 1005 - 1006 - if(d<bestDistance){ 1007 - best=item; 1008 - bestDistance=d; 1009 - } 462 + var cr=child.getBoundingClientRect(); 463 + var q=[]; 464 + Array.from(child.children||[]).forEach(function(el){ 465 + q.push({el:el,depth:1}); 1010 1010 }); 1011 1011 1012 - return bestDistance<=30 1013 - ?best 1014 - :null; 1015 - } 468 + var best=null,bestScore=-1; 1016 1016 1017 - function propagateDetailAccents(){ 1018 - if(PAGE_KIND!=="detail")return; 470 + while(q.length){ 471 + var item=q.shift(); 472 + var el=item.el; 473 + if(!visible(el))continue; 1019 1019 1020 - Array.from( 1021 - root.querySelectorAll( 1022 - ".arsn-call,.dmp-call,.ido-call,.pp-call,"+ 1023 - ".arsn-source,.dmp-source,.ido-source,.pp-source" 1024 - ) 1025 - ).forEach(function(el){ 1026 - if(!visible(el))return; 475 + var r=el.getBoundingClientRect(); 1027 1027 1028 - var style=getComputedStyle(el); 1029 - 1030 - if( 1031 - num(style.borderTopWidth)>=2 1032 - ){ 1033 - var match= 1034 - paletteMatch( 1035 - style.borderTopColor 1036 - ); 1037 - 1038 - if(match){ 1039 - el.style.setProperty( 1040 - "border-left", 1041 - "4px solid "+match.hex, 1042 - "important" 1043 - ); 477 + if(r.width>=cr.width*.72&&boxLike(el)){ 478 + var widthFit=1-Math.min(1,Math.abs(cr.width-r.width)/Math.max(1,cr.width)); 479 + var topFit=1-Math.min(1,Math.abs(cr.top-r.top)/80); 480 + var score=widthFit*5+topFit*2+Math.min(r.height,600)/600; 481 + if(score>bestScore){ 482 + best=el; 483 + bestScore=score; 1044 1044 } 1045 1045 } 1046 - }); 1047 1047 1048 - // Warning families: explicit safety override. 1049 - Array.from( 1050 - root.querySelectorAll( 1051 - ".arsn-warn,.dmp-warn,.ido-warn,.pp-warn,"+ 1052 - ".warn,.warning,.warningmessage,.errormessage" 1053 - ) 1054 - ).forEach(function(el){ 1055 - if(!visible(el))return; 1056 - 1057 - el.style.setProperty( 1058 - "border-left", 1059 - "4px solid #e94b13", 1060 - "important" 1061 - ); 1062 - }); 1063 - 1064 - // Info families: explicit orientation override. 1065 - Array.from( 1066 - root.querySelectorAll( 1067 - ".arsn-info,.dmp-info,.ido-info,.pp-info,.infomessage" 1068 - ) 1069 - ).forEach(function(el){ 1070 - if(!visible(el))return; 1071 - 1072 - el.style.setProperty( 1073 - "border-left", 1074 - "4px solid #21b6d7", 1075 - "important" 1076 - ); 1077 - }); 1078 - } 1079 - 1080 - /* ======================================================= 1081 - OVERVIEW SEMANTIC THEME PALETTE 1082 - ======================================================= */ 1083 - 1084 - function smallestThemeHeaders(){ 1085 - return Array.from( 1086 - root.querySelectorAll( 1087 - "div,span,p,strong,h3,h4,h5,h6" 1088 - ) 1089 - ).filter(function(el){ 1090 - if(!visible(el))return false; 1091 - if(!themeFor(el.textContent))return false; 1092 - 1093 - return !Array.from( 1094 - el.children||[] 1095 - ).some(function(child){ 1096 - return !!themeFor( 1097 - child.textContent 1098 - ); 1099 - }); 1100 - }); 1101 - } 1102 - 1103 - function findOverviewCard(header){ 1104 - var node=header.parentElement; 1105 - var candidates=[]; 1106 - 1107 - while(node&&node!==root){ 1108 - var rect=node.getBoundingClientRect(); 1109 - var style=getComputedStyle(node); 1110 - 1111 - var border= 1112 - num(style.borderTopWidth)+ 1113 - num(style.borderRightWidth)+ 1114 - num(style.borderBottomWidth)+ 1115 - num(style.borderLeftWidth); 1116 - 1117 - if( 1118 - rect.width>=220&& 1119 - rect.width<=800&& 1120 - rect.height>=120&& 1121 - border>=1 1122 - ){ 1123 - candidates.push(node); 487 + if(item.depth<3){ 488 + Array.from(el.children||[]).forEach(function(next){ 489 + q.push({el:next,depth:item.depth+1}); 490 + }); 1124 1124 } 1125 - 1126 - node=node.parentElement; 1127 1127 } 1128 1128 1129 - if(!candidates.length)return null; 1130 - 1131 - candidates.sort(function(a,b){ 1132 - return ( 1133 - b.getBoundingClientRect().height- 1134 - a.getBoundingClientRect().height 1135 - ); 1136 - }); 1137 - 1138 - return candidates[0]; 494 + return best; 1139 1139 } 1140 1140 1141 - function rowCandidates(link,card){ 1142 - var result=[]; 1143 - var cardRect= 1144 - card.getBoundingClientRect(); 1145 - 1146 - var node=link; 1147 - 1148 - while(node&&node!==card){ 1149 - if(visible(node)){ 1150 - var rect= 1151 - node.getBoundingClientRect(); 1152 - 1153 - if( 1154 - rect.height<=105&& 1155 - rect.width>= 1156 - cardRect.width*.50&& 1157 - rect.width<= 1158 - cardRect.width*1.03 1159 - ){ 1160 - result.push(node); 1161 - } 1162 - } 1163 - 1164 - node=node.parentElement; 1165 - } 1166 - 1167 - return result; 1168 - } 1169 - 1170 - function chooseOuterRow( 1171 - candidates, 1172 - link 1173 - ){ 1174 - if(!candidates.length){ 1175 - return link; 1176 - } 1177 - 1178 - var bordered= 1179 - candidates.filter(function(el){ 1180 - return ( 1181 - num( 1182 - getComputedStyle(el) 1183 - .borderLeftWidth 1184 - )>=1 1185 - ); 1186 - }); 1187 - 1188 - var pool= 1189 - bordered.length 1190 - ?bordered 1191 - :candidates; 1192 - 1193 - pool.sort(function(a,b){ 1194 - var ar= 1195 - a.getBoundingClientRect(); 1196 - 1197 - var br= 1198 - b.getBoundingClientRect(); 1199 - 1200 - return ( 1201 - ar.left-br.left|| 1202 - br.width-ar.width 1203 - ); 497 + function reset(){ 498 + managed.forEach(function(el){ 499 + el.style.removeProperty("min-height"); 500 + el.removeAttribute("data-sn-equal-height-managed"); 1204 1204 }); 1205 - 1206 - return pool[0]||link; 502 + managed.clear(); 1207 1207 } 1208 1208 1209 - function applyOverviewPalette(){ 1210 - if(PAGE_KIND!=="overview"){ 1211 - return []; 505 + function horizontalLayout(parent){ 506 + if(!visible(parent))return false; 507 + var s=getComputedStyle(parent); 508 + if(s.display==="grid"||s.display==="inline-grid")return true; 509 + if(s.display==="flex"||s.display==="inline-flex"){ 510 + return s.flexDirection==="row"||s.flexDirection==="row-reverse"; 1212 1212 } 1213 - 1214 - var headers= 1215 - smallestThemeHeaders() 1216 - .map(function(el){ 1217 - return { 1218 - el:el, 1219 - theme: 1220 - themeFor( 1221 - el.textContent 1222 - ), 1223 - card: 1224 - findOverviewCard( 1225 - el 1226 - ) 1227 - }; 1228 - }) 1229 - .filter(function(row){ 1230 - return !!row.card; 1231 - }); 1232 - 1233 - var unique=[]; 1234 - var seenHeaders=new Set(); 1235 - 1236 - headers.forEach(function(row){ 1237 - var key= 1238 - row.theme.name+ 1239 - "|"+ 1240 - Math.round( 1241 - row.card 1242 - .getBoundingClientRect() 1243 - .left 1244 - )+ 1245 - "|"+ 1246 - Math.round( 1247 - row.el 1248 - .getBoundingClientRect() 1249 - .top 1250 - ); 1251 - 1252 - if(!seenHeaders.has(key)){ 1253 - seenHeaders.add(key); 1254 - unique.push(row); 1255 - } 1256 - }); 1257 - 1258 - unique.forEach(function(row){ 1259 - var headerRect= 1260 - row.el 1261 - .getBoundingClientRect(); 1262 - 1263 - row.el.style.setProperty( 1264 - "background", 1265 - row.theme.bg, 1266 - "important" 1267 - ); 1268 - 1269 - row.el.style.setProperty( 1270 - "color", 1271 - row.theme.text, 1272 - "important" 1273 - ); 1274 - 1275 - row.el.style.setProperty( 1276 - "text-align", 1277 - "left", 1278 - "important" 1279 - ); 1280 - 1281 - row.el.style.setProperty( 1282 - "word-spacing", 1283 - "normal", 1284 - "important" 1285 - ); 1286 - 1287 - var later= 1288 - unique 1289 - .filter(function(other){ 1290 - return ( 1291 - other.card===row.card&& 1292 - other.el 1293 - .getBoundingClientRect() 1294 - .top> 1295 - headerRect.top+2 1296 - ); 1297 - }) 1298 - .sort(function(a,b){ 1299 - return ( 1300 - a.el 1301 - .getBoundingClientRect() 1302 - .top- 1303 - b.el 1304 - .getBoundingClientRect() 1305 - .top 1306 - ); 1307 - }); 1308 - 1309 - var stopTop= 1310 - later.length 1311 - ?later[0].el 1312 - .getBoundingClientRect() 1313 - .top 1314 - :Infinity; 1315 - 1316 - Array.from( 1317 - row.card.querySelectorAll("a") 1318 - ).forEach(function(link){ 1319 - if(!visible(link))return; 1320 - 1321 - var rect= 1322 - link.getBoundingClientRect(); 1323 - 1324 - if( 1325 - rect.top<= 1326 - headerRect.bottom-2|| 1327 - rect.top>= 1328 - stopTop-2 1329 - ){ 1330 - return; 1331 - } 1332 - 1333 - var candidates= 1334 - rowCandidates( 1335 - link, 1336 - row.card 1337 - ); 1338 - 1339 - var target= 1340 - chooseOuterRow( 1341 - candidates, 1342 - link 1343 - ); 1344 - 1345 - candidates.forEach(function(el){ 1346 - el.style.setProperty( 1347 - "border-left", 1348 - "0 solid transparent", 1349 - "important" 1350 - ); 1351 - }); 1352 - 1353 - target.style.setProperty( 1354 - "border-left", 1355 - "3px solid "+ 1356 - row.theme.accent, 1357 - "important" 1358 - ); 1359 - 1360 - target.style.setProperty( 1361 - "box-sizing", 1362 - "border-box", 1363 - "important" 1364 - ); 1365 - }); 1366 - }); 1367 - 1368 - return unique; 512 + return false; 1369 1369 } 1370 1370 1371 - /* ======================================================= 1372 - OVERVIEW CARD HEIGHT + FIRST THEMATIC ROW 1373 - ======================================================= */ 1374 - 1375 - function alignOverviewCards(headers){ 1376 - if( 1377 - PAGE_KIND!=="overview"|| 1378 - window.innerWidth<=MOBILE_MAX 1379 - ){ 1380 - return; 1381 - } 1382 - 1383 - var cards=[]; 1384 - var seen=new Set(); 1385 - 1386 - headers.forEach(function(row){ 1387 - if(!seen.has(row.card)){ 1388 - seen.add(row.card); 1389 - cards.push(row.card); 1390 - } 1391 - }); 1392 - 1393 - if(cards.length<2){ 1394 - return; 1395 - } 1396 - 1397 - // Group cards by actual top position. 515 + function rowGroups(entries){ 1398 1398 var groups=[]; 1399 - 1400 - cards.forEach(function(card){ 1401 - var top= 1402 - card.getBoundingClientRect().top; 1403 - 517 + entries.slice().sort(function(a,b){ 518 + return a.rect.top-b.rect.top||a.rect.left-b.rect.left; 519 + }).forEach(function(entry){ 1404 1404 var group=null; 1405 - 1406 1406 for(var i=0;i<groups.length;i++){ 1407 - if( 1408 - Math.abs( 1409 - groups[i].top-top 1410 - )<=ROW_TOLERANCE 1411 - ){ 522 + if(Math.abs(groups[i].top-entry.rect.top)<=ROW_TOLERANCE){ 1412 1412 group=groups[i]; 1413 1413 break; 1414 1414 } 1415 1415 } 1416 - 1417 1417 if(!group){ 1418 - group={ 1419 - top:top, 1420 - cards:[] 1421 - }; 528 + group={top:entry.rect.top,entries:[]}; 1422 1422 groups.push(group); 1423 1423 } 1424 - 1425 - group.cards.push(card); 531 + group.entries.push(entry); 1426 1426 }); 533 + return groups; 534 + } 1427 1427 1428 - groups.forEach(function(group){ 1429 - if(group.cards.length<2){ 1430 - return; 1431 - } 536 + function run(){ 537 + reset(); 1432 1432 1433 - var firstHeaders= 1434 - group.cards.map(function(card){ 1435 - var candidates= 1436 - headers 1437 - .filter(function(row){ 1438 - return row.card===card; 1439 - }) 1440 - .sort(function(a,b){ 1441 - return ( 1442 - a.el 1443 - .getBoundingClientRect() 1444 - .top- 1445 - b.el 1446 - .getBoundingClientRect() 1447 - .top 1448 - ); 1449 - }); 539 + if(window.innerWidth<=MOBILE_MAX)return; 1450 1450 1451 - return candidates.length 1452 - ?candidates[0] 1453 - :null; 1454 - }); 541 + var parents=Array.from(root.querySelectorAll("*")).filter(function(el){ 542 + return el.children&&el.children.length>=2&&horizontalLayout(el); 543 + }); 1455 1455 1456 - if( 1457 - !firstHeaders.some(function(row){ 1458 - return !row; 1459 - }) 1460 - ){ 1461 - var targetTop= 1462 - Math.max.apply( 1463 - Math, 1464 - firstHeaders.map(function(row){ 1465 - return ( 1466 - row.el 1467 - .getBoundingClientRect() 1468 - .top- 1469 - row.card 1470 - .getBoundingClientRect() 1471 - .top 1472 - ); 1473 - }) 1474 - ); 545 + parents.forEach(function(parent){ 546 + var entries=[]; 1475 1475 1476 - firstHeaders.forEach(function(row){ 1477 - var relativeTop= 1478 - row.el 1479 - .getBoundingClientRect() 1480 - .top- 1481 - row.card 1482 - .getBoundingClientRect() 1483 - .top; 1484 - 1485 - var delta= 1486 - targetTop-relativeTop; 1487 - 1488 - if(delta>1){ 1489 - saveStyle( 1490 - row.el, 1491 - originalMargin, 1492 - "margin-top" 1493 - ); 1494 - 1495 - var current= 1496 - num( 1497 - getComputedStyle( 1498 - row.el 1499 - ).marginTop 1500 - ); 1501 - 1502 - row.el.style.setProperty( 1503 - "margin-top", 1504 - ( 1505 - current+delta 1506 - )+"px" 1507 - ); 1508 - 1509 - row.el.setAttribute( 1510 - "data-sn-master-first-row", 1511 - "1" 1512 - ); 1513 - 1514 - managedMargin.add( 1515 - row.el 1516 - ); 1517 - } 548 + Array.from(parent.children).forEach(function(child){ 549 + if(!visible(child))return; 550 + var target=pickTarget(child); 551 + if(!target)return; 552 + entries.push({ 553 + target:target, 554 + rect:target.getBoundingClientRect() 1518 1518 }); 1519 - } 1520 - 1521 - var maxHeight=0; 1522 - 1523 - group.cards.forEach(function(card){ 1524 - maxHeight= 1525 - Math.max( 1526 - maxHeight, 1527 - card 1528 - .getBoundingClientRect() 1529 - .height 1530 - ); 1531 1531 }); 1532 1532 1533 - maxHeight= 1534 - Math.ceil(maxHeight); 558 + if(entries.length<2)return; 1535 1535 1536 - group.cards.forEach(function(card){ 1537 - saveStyle( 1538 - card, 1539 - originalHeight, 1540 - "min-height" 1541 - ); 560 + rowGroups(entries).forEach(function(group){ 561 + if(group.entries.length<2)return; 1542 1542 1543 - card.style.setProperty( 1544 - "min-height", 1545 - maxHeight+"px" 1546 - ); 563 + var lefts=group.entries.map(function(e){return e.rect.left;}).sort(function(a,b){return a-b;}); 564 + if(lefts[lefts.length-1]-lefts[0]<80)return; 1547 1547 1548 - card.setAttribute( 1549 - "data-sn-master-equal-height", 1550 - "1" 1551 - ); 566 + var targets=[]; 567 + var seen=new Set(); 1552 1552 1553 - managedHeight.add( 1554 - card 1555 - ); 1556 - }); 1557 - }); 1558 - } 1559 - 1560 - /* ======================================================= 1561 - DETAIL GRID EQUAL HEIGHT, DESKTOP ONLY 1562 - ======================================================= */ 1563 - 1564 - function equaliseDetailGrids(){ 1565 - if( 1566 - PAGE_KIND!=="detail"|| 1567 - window.innerWidth<=MOBILE_MAX 1568 - ){ 1569 - return; 1570 - } 1571 - 1572 - var selectors=[ 1573 - ".arsn-grid", 1574 - ".arsn-grid-2", 1575 - ".arsn-grid-3", 1576 - ".dmp-grid", 1577 - ".ido-grid", 1578 - ".pp-grid" 1579 - ]; 1580 - 1581 - selectors.forEach(function(selector){ 1582 - Array.from( 1583 - root.querySelectorAll(selector) 1584 - ).forEach(function(grid){ 1585 - var children= 1586 - Array.from( 1587 - grid.children||[] 1588 - ).filter(visible); 1589 - 1590 - if(children.length<2){ 1591 - return; 1592 - } 1593 - 1594 - var groups=[]; 1595 - 1596 - children.forEach(function(child){ 1597 - var top= 1598 - child 1599 - .getBoundingClientRect() 1600 - .top; 1601 - 1602 - var group=null; 1603 - 1604 - for(var i=0;i<groups.length;i++){ 1605 - if( 1606 - Math.abs( 1607 - groups[i].top-top 1608 - )<=ROW_TOLERANCE 1609 - ){ 1610 - group=groups[i]; 1611 - break; 1612 - } 569 + group.entries.forEach(function(e){ 570 + if(!seen.has(e.target)){ 571 + seen.add(e.target); 572 + targets.push(e.target); 1613 1613 } 574 + }); 1614 1614 1615 - if(!group){ 1616 - group={ 1617 - top:top, 1618 - items:[] 1619 - }; 1620 - groups.push(group); 1621 - } 576 + if(targets.length<2)return; 1622 1622 1623 - group.items.push(child); 578 + var max=0; 579 + targets.forEach(function(el){ 580 + max=Math.max(max,el.getBoundingClientRect().height); 1624 1624 }); 1625 1625 1626 - groups.forEach(function(group){ 1627 - if(group.items.length<2){ 1628 - return; 1629 - } 583 + max=Math.ceil(max); 584 + if(max<MIN_H)return; 1630 1630 1631 - var maxHeight=0; 1632 - 1633 - group.items.forEach(function(item){ 1634 - maxHeight= 1635 - Math.max( 1636 - maxHeight, 1637 - item 1638 - .getBoundingClientRect() 1639 - .height 1640 - ); 1641 - }); 1642 - 1643 - maxHeight= 1644 - Math.ceil(maxHeight); 1645 - 1646 - group.items.forEach(function(item){ 1647 - saveStyle( 1648 - item, 1649 - originalHeight, 1650 - "min-height" 1651 - ); 1652 - 1653 - item.style.setProperty( 1654 - "min-height", 1655 - maxHeight+"px" 1656 - ); 1657 - 1658 - item.setAttribute( 1659 - "data-sn-master-equal-height", 1660 - "1" 1661 - ); 1662 - 1663 - managedHeight.add(item); 1664 - }); 586 + targets.forEach(function(el){ 587 + el.style.setProperty("min-height",max+"px"); 588 + el.setAttribute("data-sn-equal-height-managed","1"); 589 + managed.add(el); 1665 1665 }); 1666 1666 }); 1667 1667 }); 1668 1668 } 1669 1669 1670 - /* ======================================================= 1671 - RUN / RESPONSIVE SCHEDULING 1672 - ======================================================= */ 1673 - 1674 - function run(){ 1675 - if(running)return; 1676 - 1677 - running=true; 1678 - 1679 - try{ 1680 - resetRuntime(); 1681 - applyPlaceholderBadge(); 1682 - propagateDetailAccents(); 1683 - 1684 - var headers= 1685 - applyOverviewPalette(); 1686 - 1687 - makeThreeLineAreaLabels(); 1688 - makeFilledRedOrangeCTAsBorderless(); 1689 - 1690 - if( 1691 - window.innerWidth> 1692 - MOBILE_MAX 1693 - ){ 1694 - alignOverviewCards( 1695 - headers 1696 - ); 1697 - 1698 - equaliseDetailGrids(); 1699 - } 1700 - }finally{ 1701 - running=false; 1702 - } 595 + function schedule(){ 596 + if(raf)cancelAnimationFrame(raf); 597 + raf=requestAnimationFrame(function(){ 598 + raf=requestAnimationFrame(function(){ 599 + raf=0; 600 + run(); 601 + }); 602 + }); 1703 1703 } 1704 1704 1705 - function onResize(){ 1706 - if(resizeTimer){ 1707 - clearTimeout( 1708 - resizeTimer 1709 - ); 1710 - } 605 + addEventListener("resize",schedule,{passive:true}); 606 + addEventListener("load",schedule,{once:true}); 1711 1711 1712 - resizeTimer= 1713 - setTimeout( 1714 - function(){ 1715 - resizeTimer=0; 1716 - run(); 1717 - }, 1718 - RESIZE_DEBOUNCE 1719 - ); 1720 - } 608 + root.addEventListener("click",function(){ 609 + setTimeout(schedule,0); 610 + },true); 1721 1721 1722 - async function waitForReady(){ 1723 - if( 1724 - document.readyState!=="complete" 1725 - ){ 1726 - await new Promise(function(resolve){ 1727 - window.addEventListener( 1728 - "load", 1729 - resolve, 1730 - {once:true} 1731 - ); 1732 - }); 1733 - } 1734 - 1735 - if( 1736 - document.fonts&& 1737 - document.fonts.ready 1738 - ){ 1739 - try{ 1740 - await document.fonts.ready; 1741 - }catch(error){} 1742 - } 1743 - 1744 - var images= 1745 - Array.from( 1746 - root.querySelectorAll("img") 1747 - ); 1748 - 1749 - await Promise.all( 1750 - images.map(function(img){ 1751 - if(img.complete){ 1752 - return Promise.resolve(); 1753 - } 1754 - 1755 - return new Promise(function(resolve){ 1756 - var done=function(){ 1757 - resolve(); 1758 - }; 1759 - 1760 - img.addEventListener( 1761 - "load", 1762 - done, 1763 - {once:true} 1764 - ); 1765 - 1766 - img.addEventListener( 1767 - "error", 1768 - done, 1769 - {once:true} 1770 - ); 1771 - }); 1772 - }) 1773 - ); 1774 - 1775 - run(); 612 + if(document.fonts&&document.fonts.ready){ 613 + document.fonts.ready.then(schedule); 1776 1776 } 1777 1777 1778 - window.addEventListener( 1779 - "resize", 1780 - onResize, 1781 - {passive:true} 1782 - ); 1783 - 1784 - waitForReady(); 616 + schedule(); 617 + setTimeout(schedule,250); 618 + setTimeout(schedule,900); 1785 1785 })(); 1786 1786 </script> 1787 - 1788 -<!-- SN_SERVICE_NAVIGATOR_MASTER_STYLE_END --> 621 +<!-- SN_HORIZONTAL_BOX_HARMONIZER_END --> 1789 1789 {{/html}} 1790 1790