scb-wc 0.1.53 → 0.1.55
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.
|
@@ -249,7 +249,7 @@ import{_ as U,b as J,g as Y,h as b,m as F,o as X,r as Z,y as u}from"../../vendor
|
|
|
249
249
|
${this._renderActionsMenu()}
|
|
250
250
|
</div>
|
|
251
251
|
`:e}_renderTable(){const t=this._getResolvedTableData();if(!t||!t.rows||t.rows.length===0)return null;const{alignments:e,headers:i,rows:s,rowHeaderRows:a}=this._getResolvedTableView(t),r=[this.title,this.subtitle].map(l=>typeof l=="string"?l.trim():"").filter(Boolean).join(". "),o=l=>l.html?l.html:this._escapeHtml(l.text);return u`
|
|
252
|
-
<scb-table part="table">
|
|
252
|
+
<scb-table part="table" column-width-mode="header">
|
|
253
253
|
${X(`<table class="scb-viz-table">${r?`<caption class="visually-hidden">${this._escapeHtml(r)}</caption>`:""}${i.length>0?`<thead><tr>${i.map((l,d)=>`<th scope="col" class="${e[d]==="right"?"align-right":"align-left"}">${o(l)}</th>`).join("")}</tr></thead>`:""}<tbody>${s.map((l,d)=>{const f=a[d]===!0;return`<tr>${l.map((v,S)=>{const _=e[S]==="right"?"align-right":"align-left",y=o(v);return S===0&&f?`<th scope="row" class="${_}">${y}</th>`:`<td class="${_}">${y}</td>`}).join("")}</tr>`}).join("")}</tbody></table>`)}
|
|
254
254
|
</scb-table>
|
|
255
255
|
`}_renderRichText(t){const e=typeof t=="string"?t.replace(/\r\n?/g,`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "scb-wc",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.55",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"module": "index.js",
|
|
@@ -440,5 +440,5 @@
|
|
|
440
440
|
},
|
|
441
441
|
"./mvc/*": "./mvc/*"
|
|
442
442
|
},
|
|
443
|
-
"buildHash": "
|
|
443
|
+
"buildHash": "FC3EAF78466DE3F0D8CAC743B918DCD701FF651F214F4AC3C8FB7BE5FD1FF5C6"
|
|
444
444
|
}
|
package/scb-viz/scb-viz.js
CHANGED
|
@@ -1695,7 +1695,7 @@ var H = "<svg version=\"1.1\" id=\"Lager_1\" xmlns=\"http://www.w3.org/2000/svg\
|
|
|
1695
1695
|
if (!e || !e.rows || e.rows.length === 0) return null;
|
|
1696
1696
|
let { alignments: t, headers: n, rows: r, rowHeaderRows: i } = this._getResolvedTableView(e), a = [this.title, this.subtitle].map((e) => typeof e == "string" ? e.trim() : "").filter(Boolean).join(". "), o = (e) => e.html ? e.html : this._escapeHtml(e.text);
|
|
1697
1697
|
return I`
|
|
1698
|
-
<scb-table part="table">
|
|
1698
|
+
<scb-table part="table" column-width-mode="header">
|
|
1699
1699
|
${B(`<table class="scb-viz-table">${a ? `<caption class="visually-hidden">${this._escapeHtml(a)}</caption>` : ""}${n.length > 0 ? `<thead><tr>${n.map((e, n) => `<th scope="col" class="${t[n] === "right" ? "align-right" : "align-left"}">${o(e)}</th>`).join("")}</tr></thead>` : ""}<tbody>${r.map((e, n) => {
|
|
1700
1700
|
let r = i[n] === !0;
|
|
1701
1701
|
return `<tr>${e.map((e, n) => {
|
package/scb-wc.bundle.js
CHANGED
|
@@ -13540,7 +13540,7 @@
|
|
|
13540
13540
|
${this._renderActionsMenu()}
|
|
13541
13541
|
</div>
|
|
13542
13542
|
`:t}_renderTable(){let e=this._getResolvedTableData();if(!e||!e.rows||e.rows.length===0)return null;let{alignments:t,headers:n,rows:r,rowHeaderRows:i}=this._getResolvedTableView(e),a=[this.title,this.subtitle].map(e=>typeof e==`string`?e.trim():``).filter(Boolean).join(`. `),o=e=>e.html?e.html:this._escapeHtml(e.text);return b`
|
|
13543
|
-
<scb-table part="table">
|
|
13543
|
+
<scb-table part="table" column-width-mode="header">
|
|
13544
13544
|
${yl(`<table class="scb-viz-table">${a?`<caption class="visually-hidden">${this._escapeHtml(a)}</caption>`:``}${n.length>0?`<thead><tr>${n.map((e,n)=>`<th scope="col" class="${t[n]===`right`?`align-right`:`align-left`}">${o(e)}</th>`).join(``)}</tr></thead>`:``}<tbody>${r.map((e,n)=>{let r=i[n]===!0;return`<tr>${e.map((e,n)=>{let i=t[n]===`right`?`align-right`:`align-left`,a=o(e);return n===0&&r?`<th scope="row" class="${i}">${a}</th>`:`<td class="${i}">${a}</td>`}).join(``)}</tr>`}).join(``)}</tbody></table>`)}
|
|
13545
13545
|
</scb-table>
|
|
13546
13546
|
`}_renderRichText(e){let t=typeof e==`string`?e.replace(/\r\n?/g,`
|