/*!
Copyright (c) 2026 Lenovo SSG BASD. All rights reserved.
@license Proprietary

This software is the confidential and proprietary property of Lenovo SSG BASD.
You shall not disclose such Confidential Information and shall use it only in
accordance with the terms of the license agreement.

--- Build Info ---
Version: 1.1.1
Build Time: 2026/2/26 17:21:00
Build Commit: 81e556ed827e2f043668506dae6fae8dbb9ef395
*/
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("@gsc-basic/utils");function t(e,t){return window.getComputedStyle(e,null).getPropertyValue(t)}function r(e,t){return Math.floor((e+t)/2)}exports.binarySearch=function(e,t,n,o){for(;e<t;){const i=r(e,t);if(o(e,t,i))break;n(e,t,i)?t=i:e=i}},exports.computeStyle=t,exports.getElementHeight=function(e){return e.clientHeight},exports.getLineHeight=function(e){const r=t(e,"line-height");if("normal"===r){const t=document.createElement("span");t.style.width="300px",t.style.position="absolute",t.style.visibility="hidden",t.innerText="temp",e.appendChild(t);const r=t.clientHeight;return e.removeChild(t),1.1*r}return Number.parseFloat(r)},exports.registerWordBreak=function(e){const r=t(e,"word-break"),n=t(e,"overflow-wrap");if("word-break"!==r&&"break-all"!==r&&"break-word"!==n){const t=e.style.wordBreak;return e.style.wordBreak="break-word",t}},exports.setWordBreak=function(e,t){e.style.wordBreak=t},exports.wrapTextChildNodesWithSpan=function t(r){e.isBrowser&&(r.nodeType===Node.TEXT_NODE?r.textContent&&r.parentNode?.replaceChild(function(e){const t=document.createElement("span");return t.className="l--ellipsis-js-content-text",t.textContent=e,t}(r.textContent),r):r.childNodes.forEach(e=>{t(e)}))};