bokehmol
Version:
Handle molecules with bokeh
1 lines • 64.1 kB
JSON
{"version":4,"artifacts":[{"module":{"file":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/index.js","base":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib","base_path":"index.js","canonical":"index","resolution":"ESM","id":"c27055c896","hash":"c27055c8962dedade519fb55f7b9237642b7ea670f0fb8f1b840514afd5feae1","source":"\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.bokehmol = void 0;\nconst tslib_1 = require(\"tslib\");\nconst bokehmol = tslib_1.__importStar(require(\"./models\"));\nexports.bokehmol = bokehmol;\nconst base_1 = require(\"@bokehjs/base\");\n(0, base_1.register_models)(bokehmol);\n//# sourceMappingURL=index.js.map\n","type":"js","dependency_paths":[["./models","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/index.js"]],"dependency_map":[],"exported":[],"externals":[],"shims":[]},"code":{"source":"/* index.js */ function _(require, module, exports, __esModule, __esExport) {\n __esModule();\n const tslib_1 = require(\"tslib\");\n const bokehmol = tslib_1.__importStar(require(\"2fbbcedd89\") /* ./models */);\n exports.bokehmol = bokehmol;\n const base_1 = require(\"@bokehjs/base\");\n (0, base_1.register_models)(bokehmol);\n}\n","min_source":"function _(e,o,b,s,t){s();const i=e(\"tslib\").__importStar(e(\"2fbbcedd89\"));b.bokehmol=i;(0,e(\"@bokehjs/base\").register_models)(i)}\n//# sourceMappingURL=index.min.js.map","min_map":"{\"version\":3,\"file\":\"index.min.js\",\"names\":[\"_\",\"require\",\"module\",\"exports\",\"__esModule\",\"__esExport\",\"bokehmol\",\"__importStar\",\"register_models\"],\"sources\":[\"0\"],\"mappings\":\"AAAe,SAASA,EAAEC,EAASC,EAAQC,EAASC,EAAYC,GAC5DD,IACA,MACME,EADUL,EAAQ,SACCM,aAAaN,EAAQ,eAC9CE,EAAQG,SAAWA,GAEnB,EADeL,EAAQ,iBACZO,iBAAiBF,EAChC\",\"ignoreList\":[]}"}},{"module":{"file":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/index.js","base":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib","base_path":"models/index.js","canonical":"models/index","resolution":"ESM","id":"2fbbcedd89","hash":"2fbbcedd8969ff1dda9e12e8e5db6e14bff42285b34549262950b63af4f48c7d","source":"\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.SmilesDrawerHover = exports.SmilesDrawerFormatter = exports.RDKitHover = exports.RDKitFormatter = exports.BaseHover = exports.BaseFormatter = void 0;\nvar base_formatter_1 = require(\"./base_formatter\");\nObject.defineProperty(exports, \"BaseFormatter\", { enumerable: true, get: function () { return base_formatter_1.BaseFormatter; } });\nvar base_hover_1 = require(\"./base_hover\");\nObject.defineProperty(exports, \"BaseHover\", { enumerable: true, get: function () { return base_hover_1.BaseHover; } });\nvar rdkit_formatter_1 = require(\"./rdkit_formatter\");\nObject.defineProperty(exports, \"RDKitFormatter\", { enumerable: true, get: function () { return rdkit_formatter_1.RDKitFormatter; } });\nvar rdkit_hover_1 = require(\"./rdkit_hover\");\nObject.defineProperty(exports, \"RDKitHover\", { enumerable: true, get: function () { return rdkit_hover_1.RDKitHover; } });\nvar smilesdrawer_formatter_1 = require(\"./smilesdrawer_formatter\");\nObject.defineProperty(exports, \"SmilesDrawerFormatter\", { enumerable: true, get: function () { return smilesdrawer_formatter_1.SmilesDrawerFormatter; } });\nvar smilesdrawer_hover_1 = require(\"./smilesdrawer_hover\");\nObject.defineProperty(exports, \"SmilesDrawerHover\", { enumerable: true, get: function () { return smilesdrawer_hover_1.SmilesDrawerHover; } });\n//# sourceMappingURL=index.js.map\n","type":"js","dependency_paths":[["./base_formatter","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/base_formatter.js"],["./base_hover","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/base_hover.js"],["./rdkit_formatter","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/rdkit_formatter.js"],["./rdkit_hover","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/rdkit_hover.js"],["./smilesdrawer_formatter","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/smilesdrawer_formatter.js"],["./smilesdrawer_hover","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/smilesdrawer_hover.js"]],"dependency_map":[],"exported":[{"type":"bindings","bindings":[[null,"BaseFormatter"]],"module":"./base_formatter"},{"type":"bindings","bindings":[[null,"BaseHover"]],"module":"./base_hover"},{"type":"bindings","bindings":[[null,"RDKitFormatter"]],"module":"./rdkit_formatter"},{"type":"bindings","bindings":[[null,"RDKitHover"]],"module":"./rdkit_hover"},{"type":"bindings","bindings":[[null,"SmilesDrawerFormatter"]],"module":"./smilesdrawer_formatter"},{"type":"bindings","bindings":[[null,"SmilesDrawerHover"]],"module":"./smilesdrawer_hover"}],"externals":[],"shims":[]},"code":{"source":"/* models/index.js */ function _(require, module, exports, __esModule, __esExport) {\n __esModule();\n var base_formatter_1 = require(\"bdbba644e6\") /* ./base_formatter */;\n __esExport(\"BaseFormatter\", base_formatter_1.BaseFormatter);\n var base_hover_1 = require(\"b3aabca0fa\") /* ./base_hover */;\n __esExport(\"BaseHover\", base_hover_1.BaseHover);\n var rdkit_formatter_1 = require(\"66b72b8836\") /* ./rdkit_formatter */;\n __esExport(\"RDKitFormatter\", rdkit_formatter_1.RDKitFormatter);\n var rdkit_hover_1 = require(\"db381e1cc8\") /* ./rdkit_hover */;\n __esExport(\"RDKitHover\", rdkit_hover_1.RDKitHover);\n var smilesdrawer_formatter_1 = require(\"be6f45e05e\") /* ./smilesdrawer_formatter */;\n __esExport(\"SmilesDrawerFormatter\", smilesdrawer_formatter_1.SmilesDrawerFormatter);\n var smilesdrawer_hover_1 = require(\"6c967671db\") /* ./smilesdrawer_hover */;\n __esExport(\"SmilesDrawerHover\", smilesdrawer_hover_1.SmilesDrawerHover);\n}\n","min_source":"function _(e,r,a,t,o){t(),o(\"BaseFormatter\",e(\"bdbba644e6\").BaseFormatter),o(\"BaseHover\",e(\"b3aabca0fa\").BaseHover),o(\"RDKitFormatter\",e(\"66b72b8836\").RDKitFormatter),o(\"RDKitHover\",e(\"db381e1cc8\").RDKitHover),o(\"SmilesDrawerFormatter\",e(\"be6f45e05e\").SmilesDrawerFormatter),o(\"SmilesDrawerHover\",e(\"6c967671db\").SmilesDrawerHover)}\n//# sourceMappingURL=index.min.js.map","min_map":"{\"version\":3,\"file\":\"index.min.js\",\"names\":[\"_\",\"require\",\"module\",\"exports\",\"__esModule\",\"__esExport\",\"BaseFormatter\",\"BaseHover\",\"RDKitFormatter\",\"RDKitHover\",\"SmilesDrawerFormatter\",\"SmilesDrawerHover\"],\"sources\":[\"0\"],\"mappings\":\"AAAsB,SAASA,EAAEC,EAASC,EAAQC,EAASC,EAAYC,GACnED,IAEAC,EAAW,gBADYJ,EAAQ,cACcK,eAE7CD,EAAW,YADQJ,EAAQ,cACUM,WAErCF,EAAW,iBADaJ,EAAQ,cACeO,gBAE/CH,EAAW,aADSJ,EAAQ,cACWQ,YAEvCJ,EAAW,wBADoBJ,EAAQ,cACsBS,uBAE7DL,EAAW,oBADgBJ,EAAQ,cACkBU,kBACzD\",\"ignoreList\":[]}"}},{"module":{"file":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/base_formatter.js","base":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib","base_path":"models/base_formatter.js","canonical":"models/base_formatter","resolution":"ESM","id":"bdbba644e6","hash":"bdbba644e61035ef10b75e39331147203db165ff1e461b18c95f6a5209438c5a","source":"\"use strict\";\nvar _a;\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.BaseFormatter = void 0;\nconst customjs_hover_1 = require(\"@bokehjs/models/tools/inspectors/customjs_hover\");\nconst combinesvg_1 = require(\"./combinesvg\");\nclass BaseFormatter extends customjs_hover_1.CustomJSHover {\n constructor(attrs) {\n super(attrs);\n }\n makeSVGElement() {\n const svg = document.createElementNS(\"http://www.w3.org/2000/svg\", \"svg\");\n svg.setAttribute(\"xmlns\", \"http://www.w3.org/2000/svg\");\n svg.setAttribute(\"xmlns:xlink\", \"http://www.w3.org/1999/xlink\");\n svg.setAttributeNS(null, \"width\", \"\" + this.width);\n svg.setAttributeNS(null, \"height\", \"\" + this.height);\n return svg;\n }\n draw_grid(smiles_array) {\n const images = [];\n smiles_array.forEach((smiles) => {\n let svg = this.draw_svg(smiles);\n images.push(svg);\n });\n return (0, combinesvg_1.combineSVGs)(images, this.width, this.height, this.mols_per_row);\n }\n // @ts-expect-error\n draw_svg(smiles) {\n const el = this.makeSVGElement();\n const svg = el.outerHTML;\n el.remove();\n return svg;\n }\n format(value, format, special_vars) {\n format;\n special_vars;\n return Array.isArray(value) ? this.draw_grid(value) : this.draw_svg(value);\n }\n}\nexports.BaseFormatter = BaseFormatter;\n_a = BaseFormatter;\nBaseFormatter.__name__ = \"BaseFormatter\";\nBaseFormatter.__module__ = \"bokehmol.models.base_formatter\";\n(() => {\n _a.define(({ Int }) => ({\n width: [Int, 160],\n height: [Int, 120],\n mols_per_row: [Int, 5],\n }));\n})();\n//# sourceMappingURL=base_formatter.js.map\n","type":"js","dependency_paths":[["./combinesvg","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/combinesvg.js"]],"dependency_map":[],"exported":[{"type":"named","name":"BaseFormatter"}],"externals":[],"shims":[]},"code":{"source":"/* models/base_formatter.js */ function _(require, module, exports, __esModule, __esExport) {\n var _a;\n __esModule();\n const customjs_hover_1 = require(\"@bokehjs/models/tools/inspectors/customjs_hover\");\n const combinesvg_1 = require(\"01840ae548\") /* ./combinesvg */;\n class BaseFormatter extends customjs_hover_1.CustomJSHover {\n constructor(attrs) {\n super(attrs);\n }\n makeSVGElement() {\n const svg = document.createElementNS(\"http://www.w3.org/2000/svg\", \"svg\");\n svg.setAttribute(\"xmlns\", \"http://www.w3.org/2000/svg\");\n svg.setAttribute(\"xmlns:xlink\", \"http://www.w3.org/1999/xlink\");\n svg.setAttributeNS(null, \"width\", \"\" + this.width);\n svg.setAttributeNS(null, \"height\", \"\" + this.height);\n return svg;\n }\n draw_grid(smiles_array) {\n const images = [];\n smiles_array.forEach((smiles) => {\n let svg = this.draw_svg(smiles);\n images.push(svg);\n });\n return (0, combinesvg_1.combineSVGs)(images, this.width, this.height, this.mols_per_row);\n }\n // @ts-expect-error\n draw_svg(smiles) {\n const el = this.makeSVGElement();\n const svg = el.outerHTML;\n el.remove();\n return svg;\n }\n format(value, format, special_vars) {\n format;\n special_vars;\n return Array.isArray(value) ? this.draw_grid(value) : this.draw_svg(value);\n }\n }\n exports.BaseFormatter = BaseFormatter;\n _a = BaseFormatter;\n BaseFormatter.__name__ = \"BaseFormatter\";\n BaseFormatter.__module__ = \"bokehmol.models.base_formatter\";\n (() => {\n _a.define(({ Int }) => ({\n width: [Int, 160],\n height: [Int, 120],\n mols_per_row: [Int, 5],\n }));\n })();\n}\n","min_source":"function _(t,e,r,s,o){var i;s();const h=t(\"@bokehjs/models/tools/inspectors/customjs_hover\"),n=t(\"01840ae548\");class m extends h.CustomJSHover{constructor(t){super(t)}makeSVGElement(){const t=document.createElementNS(\"http://www.w3.org/2000/svg\",\"svg\");return t.setAttribute(\"xmlns\",\"http://www.w3.org/2000/svg\"),t.setAttribute(\"xmlns:xlink\",\"http://www.w3.org/1999/xlink\"),t.setAttributeNS(null,\"width\",\"\"+this.width),t.setAttributeNS(null,\"height\",\"\"+this.height),t}draw_grid(t){const e=[];return t.forEach((t=>{let r=this.draw_svg(t);e.push(r)})),(0,n.combineSVGs)(e,this.width,this.height,this.mols_per_row)}draw_svg(t){const e=this.makeSVGElement(),r=e.outerHTML;return e.remove(),r}format(t,e,r){return Array.isArray(t)?this.draw_grid(t):this.draw_svg(t)}}r.BaseFormatter=m,i=m,m.__name__=\"BaseFormatter\",m.__module__=\"bokehmol.models.base_formatter\",i.define((({Int:t})=>({width:[t,160],height:[t,120],mols_per_row:[t,5]})))}\n//# sourceMappingURL=base_formatter.min.js.map","min_map":"{\"version\":3,\"file\":\"base_formatter.min.js\",\"names\":[\"_\",\"require\",\"module\",\"exports\",\"__esModule\",\"__esExport\",\"_a\",\"customjs_hover_1\",\"combinesvg_1\",\"BaseFormatter\",\"CustomJSHover\",\"constructor\",\"attrs\",\"super\",\"makeSVGElement\",\"svg\",\"document\",\"createElementNS\",\"setAttribute\",\"setAttributeNS\",\"this\",\"width\",\"height\",\"draw_grid\",\"smiles_array\",\"images\",\"forEach\",\"smiles\",\"draw_svg\",\"push\",\"combineSVGs\",\"mols_per_row\",\"el\",\"outerHTML\",\"remove\",\"format\",\"value\",\"special_vars\",\"Array\",\"isArray\",\"__name__\",\"__module__\",\"define\",\"Int\"],\"sources\":[\"0\"],\"mappings\":\"AAA+B,SAASA,EAAEC,EAASC,EAAQC,EAASC,EAAYC,GAC5E,IAAIC,EACJF,IACA,MAAMG,EAAmBN,EAAQ,mDAC3BO,EAAeP,EAAQ,cAC7B,MAAMQ,UAAsBF,EAAiBG,cACzC,WAAAC,CAAYC,GACRC,MAAMD,EACV,CACA,cAAAE,GACI,MAAMC,EAAMC,SAASC,gBAAgB,6BAA8B,OAKnE,OAJAF,EAAIG,aAAa,QAAS,8BAC1BH,EAAIG,aAAa,cAAe,gCAChCH,EAAII,eAAe,KAAM,QAAS,GAAKC,KAAKC,OAC5CN,EAAII,eAAe,KAAM,SAAU,GAAKC,KAAKE,QACtCP,CACX,CACA,SAAAQ,CAAUC,GACN,MAAMC,EAAS,GAKf,OAJAD,EAAaE,SAASC,IAClB,IAAIZ,EAAMK,KAAKQ,SAASD,GACxBF,EAAOI,KAAKd,EAAI,KAEb,EAAIP,EAAasB,aAAaL,EAAQL,KAAKC,MAAOD,KAAKE,OAAQF,KAAKW,aAC/E,CAEA,QAAAH,CAASD,GACL,MAAMK,EAAKZ,KAAKN,iBACVC,EAAMiB,EAAGC,UAEf,OADAD,EAAGE,SACInB,CACX,CACA,MAAAoB,CAAOC,EAAOD,EAAQE,GAGlB,OAAOC,MAAMC,QAAQH,GAAShB,KAAKG,UAAUa,GAAShB,KAAKQ,SAASQ,EACxE,EAEJjC,EAAQM,cAAgBA,EACxBH,EAAKG,EACLA,EAAc+B,SAAW,gBACzB/B,EAAcgC,WAAa,iCAEvBnC,EAAGoC,QAAO,EAAGC,UAAU,CACnBtB,MAAO,CAACsB,EAAK,KACbrB,OAAQ,CAACqB,EAAK,KACdZ,aAAc,CAACY,EAAK,MAGhC\",\"ignoreList\":[]}"}},{"module":{"file":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/combinesvg.js","base":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib","base_path":"models/combinesvg.js","canonical":"models/combinesvg","resolution":"ESM","id":"01840ae548","hash":"01840ae5484b1d9755dd76e0aa0e6b3a5e859343f0712a7e078f005d033b50bb","source":"\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.combineSVGs = combineSVGs;\nfunction combineSVGs(images, width, height, maxMolsRow) {\n let grid = [];\n let maxWidth = width;\n let maxHeight = height;\n const parser = new DOMParser();\n for (let i = 0; i < images.length; i++) {\n let svg = images[i];\n let imgWidth = width;\n let imgHeight = height;\n // handle RDKit's edge case when width or height is set to -1\n if ((width < 0) || (height < 0)) {\n // parse directly from SVG element\n let el = parser.parseFromString(svg, 'image/svg+xml').firstChild;\n if (width < 0) {\n // @ts-expect-error\n imgWidth = el.width.baseVal.value;\n if (imgWidth > maxWidth) {\n maxWidth = imgWidth;\n }\n else {\n imgWidth = maxWidth;\n }\n }\n if (height < 0)\n // @ts-expect-error\n imgHeight = el.height.baseVal.value;\n if (imgHeight > maxHeight) {\n maxHeight = imgHeight;\n }\n else {\n imgHeight = maxHeight;\n }\n }\n let x = imgWidth * (i % maxMolsRow);\n let y = imgHeight * Math.floor(i / maxMolsRow);\n let b64dump = btoa(svg);\n grid.push(`<image id=\"molecule-${i}\" transform=\"translate(${x},${y})\" href='data:image/svg+xml;base64,${b64dump}'></image>`);\n }\n const parentWidth = maxWidth * Math.min(maxMolsRow, images.length);\n const parentHeight = maxHeight * Math.ceil(images.length / maxMolsRow);\n return `<svg width=\"${parentWidth}\" height=\"${parentHeight}\">${grid.join(\"\\n\")}</svg>`;\n}\n//# sourceMappingURL=combinesvg.js.map\n","type":"js","dependency_paths":[],"dependency_map":[],"exported":[{"type":"named","name":"combineSVGs"}],"externals":[],"shims":[]},"code":{"source":"/* models/combinesvg.js */ function _(require, module, exports, __esModule, __esExport) {\n __esModule();\n exports.combineSVGs = combineSVGs;\n function combineSVGs(images, width, height, maxMolsRow) {\n let grid = [];\n let maxWidth = width;\n let maxHeight = height;\n const parser = new DOMParser();\n for (let i = 0; i < images.length; i++) {\n let svg = images[i];\n let imgWidth = width;\n let imgHeight = height;\n // handle RDKit's edge case when width or height is set to -1\n if ((width < 0) || (height < 0)) {\n // parse directly from SVG element\n let el = parser.parseFromString(svg, 'image/svg+xml').firstChild;\n if (width < 0) {\n // @ts-expect-error\n imgWidth = el.width.baseVal.value;\n if (imgWidth > maxWidth) {\n maxWidth = imgWidth;\n }\n else {\n imgWidth = maxWidth;\n }\n }\n if (height < 0)\n // @ts-expect-error\n imgHeight = el.height.baseVal.value;\n if (imgHeight > maxHeight) {\n maxHeight = imgHeight;\n }\n else {\n imgHeight = maxHeight;\n }\n }\n let x = imgWidth * (i % maxMolsRow);\n let y = imgHeight * Math.floor(i / maxMolsRow);\n let b64dump = btoa(svg);\n grid.push(`<image id=\"molecule-${i}\" transform=\"translate(${x},${y})\" href='data:image/svg+xml;base64,${b64dump}'></image>`);\n }\n const parentWidth = maxWidth * Math.min(maxMolsRow, images.length);\n const parentHeight = maxHeight * Math.ceil(images.length / maxMolsRow);\n return `<svg width=\"${parentWidth}\" height=\"${parentHeight}\">${grid.join(\"\\n\")}</svg>`;\n }\n}\n","min_source":"function _(e,t,a,l,i){l(),a.combineSVGs=function(e,t,a,l){let i=[],n=t,s=a;const h=new DOMParser;for(let g=0;g<e.length;g++){let r=e[g],o=t,m=a;if(t<0||a<0){let e=h.parseFromString(r,\"image/svg+xml\").firstChild;t<0&&(o=e.width.baseVal.value,o>n?n=o:o=n),a<0&&(m=e.height.baseVal.value),m>s?s=m:m=s}let f=o*(g%l),c=m*Math.floor(g/l),u=btoa(r);i.push(`<image id=\"molecule-${g}\" transform=\"translate(${f},${c})\" href='data:image/svg+xml;base64,${u}'></image>`)}const g=n*Math.min(l,e.length),r=s*Math.ceil(e.length/l);return`<svg width=\"${g}\" height=\"${r}\">${i.join(\"\\n\")}</svg>`}}\n//# sourceMappingURL=combinesvg.min.js.map","min_map":"{\"version\":3,\"file\":\"combinesvg.min.js\",\"names\":[\"_\",\"require\",\"module\",\"exports\",\"__esModule\",\"__esExport\",\"combineSVGs\",\"images\",\"width\",\"height\",\"maxMolsRow\",\"grid\",\"maxWidth\",\"maxHeight\",\"parser\",\"DOMParser\",\"i\",\"length\",\"svg\",\"imgWidth\",\"imgHeight\",\"el\",\"parseFromString\",\"firstChild\",\"baseVal\",\"value\",\"x\",\"y\",\"Math\",\"floor\",\"b64dump\",\"btoa\",\"push\",\"parentWidth\",\"min\",\"parentHeight\",\"ceil\",\"join\"],\"sources\":[\"0\"],\"mappings\":\"AAA2B,SAASA,EAAEC,EAASC,EAAQC,EAASC,EAAYC,GACxED,IACAD,EAAQG,YACR,SAAqBC,EAAQC,EAAOC,EAAQC,GACxC,IAAIC,EAAO,GACPC,EAAWJ,EACXK,EAAYJ,EAChB,MAAMK,EAAS,IAAIC,UACnB,IAAK,IAAIC,EAAI,EAAGA,EAAIT,EAAOU,OAAQD,IAAK,CACpC,IAAIE,EAAMX,EAAOS,GACbG,EAAWX,EACXY,EAAYX,EAEhB,GAAKD,EAAQ,GAAOC,EAAS,EAAI,CAE7B,IAAIY,EAAKP,EAAOQ,gBAAgBJ,EAAK,iBAAiBK,WAClDf,EAAQ,IAERW,EAAWE,EAAGb,MAAMgB,QAAQC,MACxBN,EAAWP,EACXA,EAAWO,EAGXA,EAAWP,GAGfH,EAAS,IAETW,EAAYC,EAAGZ,OAAOe,QAAQC,OAC9BL,EAAYP,EACZA,EAAYO,EAGZA,EAAYP,CAEpB,CACA,IAAIa,EAAIP,GAAYH,EAAIN,GACpBiB,EAAIP,EAAYQ,KAAKC,MAAMb,EAAIN,GAC/BoB,EAAUC,KAAKb,GACnBP,EAAKqB,KAAK,uBAAuBhB,2BAA2BU,KAAKC,uCAAuCG,cAC5G,CACA,MAAMG,EAAcrB,EAAWgB,KAAKM,IAAIxB,EAAYH,EAAOU,QACrDkB,EAAetB,EAAYe,KAAKQ,KAAK7B,EAAOU,OAASP,GAC3D,MAAO,eAAeuB,cAAwBE,MAAiBxB,EAAK0B,KAAK,aAC7E,CACJ\",\"ignoreList\":[]}"}},{"module":{"file":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/base_hover.js","base":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib","base_path":"models/base_hover.js","canonical":"models/base_hover","resolution":"ESM","id":"b3aabca0fa","hash":"b3aabca0fa971f2312446a601d58fe48e00f2907d360f8e860669b32ea35baa5","source":"\"use strict\";\nvar _a;\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.BaseHover = exports.BaseHoverView = void 0;\nconst dom_1 = require(\"@bokehjs/core/dom\");\nconst templating_1 = require(\"@bokehjs/core/util/templating\");\nconst types_1 = require(\"@bokehjs/core/util/types\");\nconst hover_tool_1 = require(\"@bokehjs/models/tools/inspectors/hover_tool\");\nconst icons_css_1 = require(\"@bokehjs/styles/icons.css\");\nclass BaseHoverView extends hover_tool_1.HoverToolView {\n _render_tooltips(ds, vars) {\n const { tooltips, smiles_column } = this.model;\n const i = vars.index;\n let user_tooltip = tooltips;\n if (user_tooltip === null) {\n user_tooltip = \"\";\n }\n if (!(0, types_1.isString)(user_tooltip)) {\n const template = this._template_el ?? (\n // @ts-ignore\n this._template_el = this._create_template(user_tooltip));\n // @ts-ignore\n user_tooltip = this._render_template(template, user_tooltip, ds, vars).outerHTML;\n }\n const mol_tooltip = \"<div>@\" + smiles_column + \"{custom}</div>\" + user_tooltip;\n const content = (0, templating_1.replace_placeholders)({ html: mol_tooltip }, ds, i, this.model.formatters, vars);\n return (0, dom_1.div)(content);\n }\n}\nexports.BaseHoverView = BaseHoverView;\nBaseHoverView.__name__ = \"BaseHoverView\";\nclass BaseHover extends hover_tool_1.HoverTool {\n get computed_icon() {\n return \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAMAAADzapwJAAAAt1BMVEUAAAAAAAArKyskJCQcHBwrKyscHBwmJiYjIyMhISEgICAfHx8dHR0kJCQiIiIhISEhISEgICAkJCQkJCQjIyMiIiIiIiIhISEkJCQjIyMiIiIiIiIjIyMjIyMkJCQjIyMiIiIkJCQhISEjIyMiIiIiIiIiIiIkJCQjIyMiIiIiIiIiIiIiIiIhISEjIyMjIyMiIiIiIiIjIyMiIiIiIiIhISEiIiIiIiIiIiIiIiIhISEjIyP///9o30WSAAAAPHRSTlMAAQYHCQwSFBYXGBkaKy0uLzAxMjM0NTY5UVJTV1hdYHJyc3V3eHmBk5SVlpeZmpucnaqtrrCytLa7wMBTv07WAAAAAWJLR0Q8p2phzwAAAKRJREFUGBmtwQkagUAAgNF/ZAtZo2yRIrusofvfi+ab0gG8xx85gS8FDjlabJuS/db4WQ1RRksy+p3ZRZpxbZA6t8gYJxRzTc7WQhKPCjnlSJDwXEIdRQ9xPRKeS+eAcurjeiTEo8JhgNTdU44EUm9D9SlIRDV2FkrYZjHhazrHOJLS7xReRSi+CtzqZJYjmiUoNRn7/GixbUr2WyPHCXwpcPifD0UBD3u/QqniAAAAAElFTkSuQmCC\";\n }\n constructor(attrs) {\n super(attrs);\n this.tool_icon = icons_css_1.tool_icon_hover;\n }\n}\nexports.BaseHover = BaseHover;\n_a = BaseHover;\nBaseHover.__name__ = \"BaseHover\";\nBaseHover.__module__ = \"bokehmol.models.base_hover\";\n(() => {\n _a.prototype.default_view = BaseHoverView;\n _a.define(({ Str, Int }) => ({\n smiles_column: [Str, \"SMILES\"],\n width: [Int, 160],\n height: [Int, 120],\n mols_per_row: [Int, 3],\n }));\n _a.override({\n tooltips: [],\n });\n})();\n//# sourceMappingURL=base_hover.js.map\n","type":"js","dependency_paths":[],"dependency_map":[],"exported":[{"type":"named","name":"BaseHoverView"},{"type":"named","name":"BaseHover"}],"externals":[],"shims":[]},"code":{"source":"/* models/base_hover.js */ function _(require, module, exports, __esModule, __esExport) {\n var _a;\n __esModule();\n const dom_1 = require(\"@bokehjs/core/dom\");\n const templating_1 = require(\"@bokehjs/core/util/templating\");\n const types_1 = require(\"@bokehjs/core/util/types\");\n const hover_tool_1 = require(\"@bokehjs/models/tools/inspectors/hover_tool\");\n const icons_css_1 = require(\"@bokehjs/styles/icons.css\");\n class BaseHoverView extends hover_tool_1.HoverToolView {\n _render_tooltips(ds, vars) {\n const { tooltips, smiles_column } = this.model;\n const i = vars.index;\n let user_tooltip = tooltips;\n if (user_tooltip === null) {\n user_tooltip = \"\";\n }\n if (!(0, types_1.isString)(user_tooltip)) {\n const template = this._template_el ?? (\n // @ts-ignore\n this._template_el = this._create_template(user_tooltip));\n // @ts-ignore\n user_tooltip = this._render_template(template, user_tooltip, ds, vars).outerHTML;\n }\n const mol_tooltip = \"<div>@\" + smiles_column + \"{custom}</div>\" + user_tooltip;\n const content = (0, templating_1.replace_placeholders)({ html: mol_tooltip }, ds, i, this.model.formatters, vars);\n return (0, dom_1.div)(content);\n }\n }\n exports.BaseHoverView = BaseHoverView;\n BaseHoverView.__name__ = \"BaseHoverView\";\n class BaseHover extends hover_tool_1.HoverTool {\n get computed_icon() {\n return \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAMAAADzapwJAAAAt1BMVEUAAAAAAAArKyskJCQcHBwrKyscHBwmJiYjIyMhISEgICAfHx8dHR0kJCQiIiIhISEhISEgICAkJCQkJCQjIyMiIiIiIiIhISEkJCQjIyMiIiIiIiIjIyMjIyMkJCQjIyMiIiIkJCQhISEjIyMiIiIiIiIiIiIkJCQjIyMiIiIiIiIiIiIiIiIhISEjIyMjIyMiIiIiIiIjIyMiIiIiIiIhISEiIiIiIiIiIiIiIiIhISEjIyP///9o30WSAAAAPHRSTlMAAQYHCQwSFBYXGBkaKy0uLzAxMjM0NTY5UVJTV1hdYHJyc3V3eHmBk5SVlpeZmpucnaqtrrCytLa7wMBTv07WAAAAAWJLR0Q8p2phzwAAAKRJREFUGBmtwQkagUAAgNF/ZAtZo2yRIrusofvfi+ab0gG8xx85gS8FDjlabJuS/db4WQ1RRksy+p3ZRZpxbZA6t8gYJxRzTc7WQhKPCjnlSJDwXEIdRQ9xPRKeS+eAcurjeiTEo8JhgNTdU44EUm9D9SlIRDV2FkrYZjHhazrHOJLS7xReRSi+CtzqZJYjmiUoNRn7/GixbUr2WyPHCXwpcPifD0UBD3u/QqniAAAAAElFTkSuQmCC\";\n }\n constructor(attrs) {\n super(attrs);\n this.tool_icon = icons_css_1.tool_icon_hover;\n }\n }\n exports.BaseHover = BaseHover;\n _a = BaseHover;\n BaseHover.__name__ = \"BaseHover\";\n BaseHover.__module__ = \"bokehmol.models.base_hover\";\n (() => {\n _a.prototype.default_view = BaseHoverView;\n _a.define(({ Str, Int }) => ({\n smiles_column: [Str, \"SMILES\"],\n width: [Int, 160],\n height: [Int, 120],\n mols_per_row: [Int, 3],\n }));\n _a.override({\n tooltips: [],\n });\n })();\n}\n","min_source":"function _(e,i,o,I,t){var s;I();const A=e(\"@bokehjs/core/dom\"),r=e(\"@bokehjs/core/util/templating\"),l=e(\"@bokehjs/core/util/types\"),h=e(\"@bokehjs/models/tools/inspectors/hover_tool\"),_=e(\"@bokehjs/styles/icons.css\");class n extends h.HoverToolView{_render_tooltips(e,i){const{tooltips:o,smiles_column:I}=this.model,t=i.index;let s=o;if(null===s&&(s=\"\"),!(0,l.isString)(s)){const o=this._template_el??(this._template_el=this._create_template(s));s=this._render_template(o,s,e,i).outerHTML}const h=\"<div>@\"+I+\"{custom}</div>\"+s,_=(0,r.replace_placeholders)({html:h},e,t,this.model.formatters,i);return(0,A.div)(_)}}o.BaseHoverView=n,n.__name__=\"BaseHoverView\";class a extends h.HoverTool{get computed_icon(){return\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAMAAADzapwJAAAAt1BMVEUAAAAAAAArKyskJCQcHBwrKyscHBwmJiYjIyMhISEgICAfHx8dHR0kJCQiIiIhISEhISEgICAkJCQkJCQjIyMiIiIiIiIhISEkJCQjIyMiIiIiIiIjIyMjIyMkJCQjIyMiIiIkJCQhISEjIyMiIiIiIiIiIiIkJCQjIyMiIiIiIiIiIiIiIiIhISEjIyMjIyMiIiIiIiIjIyMiIiIiIiIhISEiIiIiIiIiIiIiIiIhISEjIyP///9o30WSAAAAPHRSTlMAAQYHCQwSFBYXGBkaKy0uLzAxMjM0NTY5UVJTV1hdYHJyc3V3eHmBk5SVlpeZmpucnaqtrrCytLa7wMBTv07WAAAAAWJLR0Q8p2phzwAAAKRJREFUGBmtwQkagUAAgNF/ZAtZo2yRIrusofvfi+ab0gG8xx85gS8FDjlabJuS/db4WQ1RRksy+p3ZRZpxbZA6t8gYJxRzTc7WQhKPCjnlSJDwXEIdRQ9xPRKeS+eAcurjeiTEo8JhgNTdU44EUm9D9SlIRDV2FkrYZjHhazrHOJLS7xReRSi+CtzqZJYjmiUoNRn7/GixbUr2WyPHCXwpcPifD0UBD3u/QqniAAAAAElFTkSuQmCC\"}constructor(e){super(e),this.tool_icon=_.tool_icon_hover}}o.BaseHover=a,s=a,a.__name__=\"BaseHover\",a.__module__=\"bokehmol.models.base_hover\",s.prototype.default_view=n,s.define((({Str:e,Int:i})=>({smiles_column:[e,\"SMILES\"],width:[i,160],height:[i,120],mols_per_row:[i,3]}))),s.override({tooltips:[]})}\n//# sourceMappingURL=base_hover.min.js.map","min_map":"{\"version\":3,\"file\":\"base_hover.min.js\",\"names\":[\"_\",\"require\",\"module\",\"exports\",\"__esModule\",\"__esExport\",\"_a\",\"dom_1\",\"templating_1\",\"types_1\",\"hover_tool_1\",\"icons_css_1\",\"BaseHoverView\",\"HoverToolView\",\"_render_tooltips\",\"ds\",\"vars\",\"tooltips\",\"smiles_column\",\"this\",\"model\",\"i\",\"index\",\"user_tooltip\",\"isString\",\"template\",\"_template_el\",\"_create_template\",\"_render_template\",\"outerHTML\",\"mol_tooltip\",\"content\",\"replace_placeholders\",\"html\",\"formatters\",\"div\",\"__name__\",\"BaseHover\",\"HoverTool\",\"computed_icon\",\"constructor\",\"attrs\",\"super\",\"tool_icon\",\"tool_icon_hover\",\"__module__\",\"prototype\",\"default_view\",\"define\",\"Str\",\"Int\",\"width\",\"height\",\"mols_per_row\",\"override\"],\"sources\":[\"0\"],\"mappings\":\"AAA2B,SAASA,EAAEC,EAASC,EAAQC,EAASC,EAAYC,GACxE,IAAIC,EACJF,IACA,MAAMG,EAAQN,EAAQ,qBAChBO,EAAeP,EAAQ,iCACvBQ,EAAUR,EAAQ,4BAClBS,EAAeT,EAAQ,+CACvBU,EAAcV,EAAQ,6BAC5B,MAAMW,UAAsBF,EAAaG,cACrC,gBAAAC,CAAiBC,EAAIC,GACjB,MAAMC,SAAEA,EAAQC,cAAEA,GAAkBC,KAAKC,MACnCC,EAAIL,EAAKM,MACf,IAAIC,EAAeN,EAInB,GAHqB,OAAjBM,IACAA,EAAe,MAEd,EAAId,EAAQe,UAAUD,GAAe,CACtC,MAAME,EAAWN,KAAKO,eAEtBP,KAAKO,aAAeP,KAAKQ,iBAAiBJ,IAE1CA,EAAeJ,KAAKS,iBAAiBH,EAAUF,EAAcR,EAAIC,GAAMa,SAC3E,CACA,MAAMC,EAAc,SAAWZ,EAAgB,iBAAmBK,EAC5DQ,GAAU,EAAIvB,EAAawB,sBAAsB,CAAEC,KAAMH,GAAef,EAAIM,EAAGF,KAAKC,MAAMc,WAAYlB,GAC5G,OAAO,EAAIT,EAAM4B,KAAKJ,EAC1B,EAEJ5B,EAAQS,cAAgBA,EACxBA,EAAcwB,SAAW,gBACzB,MAAMC,UAAkB3B,EAAa4B,UACjC,iBAAIC,GACA,MAAO,orBACX,CACA,WAAAC,CAAYC,GACRC,MAAMD,GACNtB,KAAKwB,UAAYhC,EAAYiC,eACjC,EAEJzC,EAAQkC,UAAYA,EACpB/B,EAAK+B,EACLA,EAAUD,SAAW,YACrBC,EAAUQ,WAAa,6BAEnBvC,EAAGwC,UAAUC,aAAenC,EAC5BN,EAAG0C,QAAO,EAAGC,MAAKC,UAAU,CACxBhC,cAAe,CAAC+B,EAAK,UACrBE,MAAO,CAACD,EAAK,KACbE,OAAQ,CAACF,EAAK,KACdG,aAAc,CAACH,EAAK,OAExB5C,EAAGgD,SAAS,CACRrC,SAAU,IAGtB\",\"ignoreList\":[]}"}},{"module":{"file":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/rdkit_formatter.js","base":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib","base_path":"models/rdkit_formatter.js","canonical":"models/rdkit_formatter","resolution":"ESM","id":"66b72b8836","hash":"66b72b8836cd47d458d69158e17fc6595a1c77dfeddee0687692678ff91aa3c3","source":"\"use strict\";\nvar _a;\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.RDKitFormatter = void 0;\nconst base_formatter_1 = require(\"./base_formatter\");\nclass RDKitFormatter extends base_formatter_1.BaseFormatter {\n constructor(attrs) {\n super(attrs);\n }\n initialize() {\n super.initialize();\n this.onRDKitReady(true, false, () => {\n // @ts-expect-error\n initRDKitModule().then((RDKitModule) => {\n this.RDKitModule = RDKitModule;\n console.log(\"RDKit version: \" + RDKitModule.version());\n });\n });\n }\n onRDKitReady(init, lib, callback) {\n this.hasLoadedRDKit(init, lib) ? callback() : setTimeout(() => {\n this.onRDKitReady(init, lib, callback);\n }, 100);\n }\n hasLoadedRDKit(init, lib) {\n // @ts-expect-error\n return (init ? typeof initRDKitModule !== \"undefined\" : true)\n && (lib ? typeof this.RDKitModule !== \"undefined\" : true);\n }\n setupRDKitOptions() {\n this.onRDKitReady(true, true, () => {\n this.RDKitModule.prefer_coordgen(this.prefer_coordgen);\n });\n this.json_mol_opts = JSON.stringify({\n removeHs: this.remove_hs,\n sanitize: this.sanitize,\n kekulize: this.kekulize,\n });\n this.json_draw_opts = JSON.stringify({\n width: this.width,\n height: this.height,\n ...this.draw_options,\n });\n return this.json_draw_opts;\n }\n draw_svg(smiles) {\n const draw_opts = this.json_draw_opts ?? this.setupRDKitOptions();\n var mol;\n this.onRDKitReady(true, true, () => {\n mol = this.RDKitModule.get_mol(smiles, this.json_mol_opts);\n });\n // @ts-expect-error\n if (typeof mol === \"undefined\") {\n console.log(\"Attempting to display structures before RDKit has been loaded.\");\n }\n else if (mol !== null && mol.is_valid()) {\n const svg = mol.get_svg_with_highlights(draw_opts);\n mol.delete();\n return svg;\n }\n return super.draw_svg(smiles);\n }\n}\nexports.RDKitFormatter = RDKitFormatter;\n_a = RDKitFormatter;\nRDKitFormatter.__name__ = \"RDKitFormatter\";\nRDKitFormatter.__module__ = \"bokehmol.models.rdkit_formatter\";\n(() => {\n _a.define(({ Bool, Dict, Unknown }) => ({\n prefer_coordgen: [Bool, true],\n remove_hs: [Bool, true],\n sanitize: [Bool, true],\n kekulize: [Bool, true],\n draw_options: [Dict(Unknown), {}],\n }));\n})();\n//# sourceMappingURL=rdkit_formatter.js.map\n","type":"js","dependency_paths":[["./base_formatter","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/base_formatter.js"]],"dependency_map":[],"exported":[{"type":"named","name":"RDKitFormatter"}],"externals":[],"shims":[]},"code":{"source":"/* models/rdkit_formatter.js */ function _(require, module, exports, __esModule, __esExport) {\n var _a;\n __esModule();\n const base_formatter_1 = require(\"bdbba644e6\") /* ./base_formatter */;\n class RDKitFormatter extends base_formatter_1.BaseFormatter {\n constructor(attrs) {\n super(attrs);\n }\n initialize() {\n super.initialize();\n this.onRDKitReady(true, false, () => {\n // @ts-expect-error\n initRDKitModule().then((RDKitModule) => {\n this.RDKitModule = RDKitModule;\n console.log(\"RDKit version: \" + RDKitModule.version());\n });\n });\n }\n onRDKitReady(init, lib, callback) {\n this.hasLoadedRDKit(init, lib) ? callback() : setTimeout(() => {\n this.onRDKitReady(init, lib, callback);\n }, 100);\n }\n hasLoadedRDKit(init, lib) {\n // @ts-expect-error\n return (init ? typeof initRDKitModule !== \"undefined\" : true)\n && (lib ? typeof this.RDKitModule !== \"undefined\" : true);\n }\n setupRDKitOptions() {\n this.onRDKitReady(true, true, () => {\n this.RDKitModule.prefer_coordgen(this.prefer_coordgen);\n });\n this.json_mol_opts = JSON.stringify({\n removeHs: this.remove_hs,\n sanitize: this.sanitize,\n kekulize: this.kekulize,\n });\n this.json_draw_opts = JSON.stringify({\n width: this.width,\n height: this.height,\n ...this.draw_options,\n });\n return this.json_draw_opts;\n }\n draw_svg(smiles) {\n const draw_opts = this.json_draw_opts ?? this.setupRDKitOptions();\n var mol;\n this.onRDKitReady(true, true, () => {\n mol = this.RDKitModule.get_mol(smiles, this.json_mol_opts);\n });\n // @ts-expect-error\n if (typeof mol === \"undefined\") {\n console.log(\"Attempting to display structures before RDKit has been loaded.\");\n }\n else if (mol !== null && mol.is_valid()) {\n const svg = mol.get_svg_with_highlights(draw_opts);\n mol.delete();\n return svg;\n }\n return super.draw_svg(smiles);\n }\n }\n exports.RDKitFormatter = RDKitFormatter;\n _a = RDKitFormatter;\n RDKitFormatter.__name__ = \"RDKitFormatter\";\n RDKitFormatter.__module__ = \"bokehmol.models.rdkit_formatter\";\n (() => {\n _a.define(({ Bool, Dict, Unknown }) => ({\n prefer_coordgen: [Bool, true],\n remove_hs: [Bool, true],\n sanitize: [Bool, true],\n kekulize: [Bool, true],\n draw_options: [Dict(Unknown), {}],\n }));\n })();\n}\n","min_source":"function _(t,i,e,s,o){var n;s();const r=t(\"bdbba644e6\");class d extends r.BaseFormatter{constructor(t){super(t)}initialize(){super.initialize(),this.onRDKitReady(!0,!1,(()=>{initRDKitModule().then((t=>{this.RDKitModule=t,console.log(\"RDKit version: \"+t.version())}))}))}onRDKitReady(t,i,e){this.hasLoadedRDKit(t,i)?e():setTimeout((()=>{this.onRDKitReady(t,i,e)}),100)}hasLoadedRDKit(t,i){return!(t&&\"undefined\"==typeof initRDKitModule||i&&void 0===this.RDKitModule)}setupRDKitOptions(){return this.onRDKitReady(!0,!0,(()=>{this.RDKitModule.prefer_coordgen(this.prefer_coordgen)})),this.json_mol_opts=JSON.stringify({removeHs:this.remove_hs,sanitize:this.sanitize,kekulize:this.kekulize}),this.json_draw_opts=JSON.stringify({width:this.width,height:this.height,...this.draw_options}),this.json_draw_opts}draw_svg(t){const i=this.json_draw_opts??this.setupRDKitOptions();var e;if(this.onRDKitReady(!0,!0,(()=>{e=this.RDKitModule.get_mol(t,this.json_mol_opts)})),void 0===e)console.log(\"Attempting to display structures before RDKit has been loaded.\");else if(null!==e&&e.is_valid()){const t=e.get_svg_with_highlights(i);return e.delete(),t}return super.draw_svg(t)}}e.RDKitFormatter=d,n=d,d.__name__=\"RDKitFormatter\",d.__module__=\"bokehmol.models.rdkit_formatter\",n.define((({Bool:t,Dict:i,Unknown:e})=>({prefer_coordgen:[t,!0],remove_hs:[t,!0],sanitize:[t,!0],kekulize:[t,!0],draw_options:[i(e),{}]})))}\n//# sourceMappingURL=rdkit_formatter.min.js.map","min_map":"{\"version\":3,\"file\":\"rdkit_formatter.min.js\",\"names\":[\"_\",\"require\",\"module\",\"exports\",\"__esModule\",\"__esExport\",\"_a\",\"base_formatter_1\",\"RDKitFormatter\",\"BaseFormatter\",\"constructor\",\"attrs\",\"super\",\"initialize\",\"this\",\"onRDKitReady\",\"initRDKitModule\",\"then\",\"RDKitModule\",\"console\",\"log\",\"version\",\"init\",\"lib\",\"callback\",\"hasLoadedRDKit\",\"setTimeout\",\"setupRDKitOptions\",\"prefer_coordgen\",\"json_mol_opts\",\"JSON\",\"stringify\",\"removeHs\",\"remove_hs\",\"sanitize\",\"kekulize\",\"json_draw_opts\",\"width\",\"height\",\"draw_options\",\"draw_svg\",\"smiles\",\"draw_opts\",\"mol\",\"get_mol\",\"is_valid\",\"svg\",\"get_svg_with_highlights\",\"delete\",\"__name__\",\"__module__\",\"define\",\"Bool\",\"Dict\",\"Unknown\"],\"sources\":[\"0\"],\"mappings\":\"AAAgC,SAASA,EAAEC,EAASC,EAAQC,EAASC,EAAYC,GAC7E,IAAIC,EACJF,IACA,MAAMG,EAAmBN,EAAQ,cACjC,MAAMO,UAAuBD,EAAiBE,cAC1C,WAAAC,CAAYC,GACRC,MAAMD,EACV,CACA,UAAAE,GACID,MAAMC,aACNC,KAAKC,cAAa,GAAM,GAAO,KAE3BC,kBAAkBC,MAAMC,IACpBJ,KAAKI,YAAcA,EACnBC,QAAQC,IAAI,kBAAoBF,EAAYG,UAAU,GACxD,GAEV,CACA,YAAAN,CAAaO,EAAMC,EAAKC,GACpBV,KAAKW,eAAeH,EAAMC,GAAOC,IAAaE,YAAW,KACrDZ,KAAKC,aAAaO,EAAMC,EAAKC,EAAS,GACvC,IACP,CACA,cAAAC,CAAeH,EAAMC,GAEjB,QAAQD,GAAkC,oBAApBN,iBACdO,QAAkC,IAArBT,KAAKI,YAC9B,CACA,iBAAAS,GAcI,OAbAb,KAAKC,cAAa,GAAM,GAAM,KAC1BD,KAAKI,YAAYU,gBAAgBd,KAAKc,gBAAgB,IAE1Dd,KAAKe,cAAgBC,KAAKC,UAAU,CAChCC,SAAUlB,KAAKmB,UACfC,SAAUpB,KAAKoB,SACfC,SAAUrB,KAAKqB,WAEnBrB,KAAKsB,eAAiBN,KAAKC,UAAU,CACjCM,MAAOvB,KAAKuB,MACZC,OAAQxB,KAAKwB,UACVxB,KAAKyB,eAELzB,KAAKsB,cAChB,CACA,QAAAI,CAASC,GACL,MAAMC,EAAY5B,KAAKsB,gBAAkBtB,KAAKa,oBAC9C,IAAIgB,EAKJ,GAJA7B,KAAKC,cAAa,GAAM,GAAM,KAC1B4B,EAAM7B,KAAKI,YAAY0B,QAAQH,EAAQ3B,KAAKe,cAAc,SAG3C,IAARc,EACPxB,QAAQC,IAAI,uEAEX,GAAY,OAARuB,GAAgBA,EAAIE,WAAY,CACrC,MAAMC,EAAMH,EAAII,wBAAwBL,GAExC,OADAC,EAAIK,SACGF,CACX,CACA,OAAOlC,MAAM4B,SAASC,EAC1B,EAEJtC,EAAQK,eAAiBA,EACzBF,EAAKE,EACLA,EAAeyC,SAAW,iBAC1BzC,EAAe0C,WAAa,kCAExB5C,EAAG6C,QAAO,EAAGC,OAAMC,OAAMC,cAAc,CACnC1B,gBAAiB,CAACwB,GAAM,GACxBnB,UAAW,CAACmB,GAAM,GAClBlB,SAAU,CAACkB,GAAM,GACjBjB,SAAU,CAACiB,GAAM,GACjBb,aAAc,CAACc,EAAKC,GAAU,CAAC,MAG3C\",\"ignoreList\":[]}"}},{"module":{"file":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/rdkit_hover.js","base":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib","base_path":"models/rdkit_hover.js","canonical":"models/rdkit_hover","resolution":"ESM","id":"db381e1cc8","hash":"db381e1cc85ad4442356bb498f5bc6eafe36d42733f4631636ff98bdbb1c65ce","source":"\"use strict\";\nvar _a;\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.RDKitHover = exports.RDKitHoverView = void 0;\nconst base_hover_1 = require(\"./base_hover\");\nconst rdkit_formatter_1 = require(\"./rdkit_formatter\");\nclass RDKitHoverView extends base_hover_1.BaseHoverView {\n initialize() {\n super.initialize();\n const { formatters, smiles_column, width, height, mols_per_row, prefer_coordgen, remove_hs, sanitize, kekulize, draw_options } = this.model;\n // @ts-expect-error\n formatters[\"@\" + smiles_column] = new rdkit_formatter_1.RDKitFormatter({\n width: width,\n height: height,\n mols_per_row: mols_per_row,\n prefer_coordgen: prefer_coordgen,\n remove_hs: remove_hs,\n sanitize: sanitize,\n kekulize: kekulize,\n draw_options: draw_options,\n });\n }\n}\nexports.RDKitHoverView = RDKitHoverView;\nRDKitHoverView.__name__ = \"RDKitHoverView\";\nclass RDKitHover extends base_hover_1.BaseHover {\n get computed_icon() {\n return \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAFVBMVEXc3NwUFP8UPP9kZP+MjP+0tP////9ZXZotAAAAAXRSTlMAQObYZgAAAAFiS0dEBmFmuH0AAAAHdElNRQfmAwsPGi+MyC9RAAAAQElEQVQI12NgQABGQUEBMENISUkRLKBsbGwEEhIyBgJFsICLC0iIUdnExcUZwnANQWfApKCK4doRBsKtQFgKAQC5Ww1JEHSEkAAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wMy0xMVQxNToyNjo0NyswMDowMDzr2J4AAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMDMtMTFUMTU6MjY6NDcrMDA6MDBNtmAiAAAAAElFTkSuQmCC\";\n }\n constructor(attrs) {\n super(attrs);\n this.tool_name = \"RDKit Hover\";\n }\n}\nexports.RDKitHover = RDKitHover;\n_a = RDKitHover;\nRDKitHover.__name__ = \"RDKitHover\";\nRDKitHover.__module__ = \"bokehmol.models.rdkit_hover\";\n(() => {\n _a.prototype.default_view = RDKitHoverView;\n _a.define(({ Bool, Dict, Unknown }) => ({\n prefer_coordgen: [Bool, true],\n remove_hs: [Bool, true],\n sanitize: [Bool, true],\n kekulize: [Bool, true],\n draw_options: [Dict(Unknown), {}],\n }));\n _a.register_alias(\"rdkit_hover\", () => new _a());\n})();\n//# sourceMappingURL=rdkit_hover.js.map\n","type":"js","dependency_paths":[["./base_hover","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/base_hover.js"],["./rdkit_formatter","/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/rdkit_formatter.js"]],"dependency_map":[],"exported":[{"type":"named","name":"RDKitHoverView"},{"type":"named","name":"RDKitHover"}],"externals":[],"shims":[]},"code":{"source":"/* models/rdkit_hover.js */ function _(require, module, exports, __esModule, __esExport) {\n var _a;\n __esModule();\n const base_hover_1 = require(\"b3aabca0fa\") /* ./base_hover */;\n const rdkit_formatter_1 = require(\"66b72b8836\") /* ./rdkit_formatter */;\n class RDKitHoverView extends base_hover_1.BaseHoverView {\n initialize() {\n super.initialize();\n const { formatters, smiles_column, width, height, mols_per_row, prefer_coordgen, remove_hs, sanitize, kekulize, draw_options } = this.model;\n // @ts-expect-error\n formatters[\"@\" + smiles_column] = new rdkit_formatter_1.RDKitFormatter({\n width: width,\n height: height,\n mols_per_row: mols_per_row,\n prefer_coordgen: prefer_coordgen,\n remove_hs: remove_hs,\n sanitize: sanitize,\n kekulize: kekulize,\n draw_options: draw_options,\n });\n }\n }\n exports.RDKitHoverView = RDKitHoverView;\n RDKitHoverView.__name__ = \"RDKitHoverView\";\n class RDKitHover extends base_hover_1.BaseHover {\n get computed_icon() {\n return \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAFVBMVEXc3NwUFP8UPP9kZP+MjP+0tP////9ZXZotAAAAAXRSTlMAQObYZgAAAAFiS0dEBmFmuH0AAAAHdElNRQfmAwsPGi+MyC9RAAAAQElEQVQI12NgQABGQUEBMENISUkRLKBsbGwEEhIyBgJFsICLC0iIUdnExcUZwnANQWfApKCK4doRBsKtQFgKAQC5Ww1JEHSEkAAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wMy0xMVQxNToyNjo0NyswMDowMDzr2J4AAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMDMtMTFUMTU6MjY6NDcrMDA6MDBNtmAiAAAAAElFTkSuQmCC\";\n }\n constructor(attrs) {\n super(attrs);\n this.tool_name = \"RDKit Hover\";\n }\n }\n exports.RDKitHover = RDKitHover;\n _a = RDKitHover;\n RDKitHover.__name__ = \"RDKitHover\";\n RDKitHover.__module__ = \"bokehmol.models.rdkit_hover\";\n (() => {\n _a.prototype.default_view = RDKitHoverView;\n _a.define(({ Bool, Dict, Unknown }) => ({\n prefer_coordgen: [Bool, true],\n remove_hs: [Bool, true],\n sanitize: [Bool, true],\n kekulize: [Bool, true],\n draw_options: [Dict(Unknown), {}],\n }));\n _a.register_alias(\"rdkit_hover\", () => new _a());\n })();\n}\n","min_source":"function _(A,e,o,i,t){var r;i();const s=A(\"b3aabca0fa\"),n=A(\"66b72b8836\");class _ extends s.BaseHoverView{initialize(){super.initialize();const{formatters:A,smiles_column:e,width:o,height:i,mols_per_row:t,prefer_coordgen:r,remove_hs:s,sanitize:_,kekulize:a,draw_options:d}=this.model;A[\"@\"+e]=new n.RDKitFormatter({width:o,height:i,mols_per_row:t,prefer_coordgen:r,remove_hs:s,sanitize:_,kekulize:a,draw_options:d})}}o.RDKitHoverView=_,_.__name__=\"RDKitHoverView\";class a extends s.BaseHover{get computed_icon(){return\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAFVBMVEXc3NwUFP8UPP9kZP+MjP+0tP////9ZXZotAAAAAXRSTlMAQObYZgAAAAFiS0dEBmFmuH0AAAAHdElNRQfmAwsPGi+MyC9RAAAAQElEQVQI12NgQABGQUEBMENISUkRLKBsbGwEEhIyBgJFsICLC0iIUdnExcUZwnANQWfApKCK4doRBsKtQFgKAQC5Ww1JEHSEkAAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wMy0xMVQxNToyNjo0NyswMDowMDzr2J4AAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMDMtMTFUMTU6MjY6NDcrMDA6MDBNtmAiAAAAAElFTkSuQmCC\"}constructor(A){super(A),this.tool_name=\"RDKit Hover\"}}o.RDKitHover=a,r=a,a.__name__=\"RDKitHover\",a.__module__=\"bokehmol.models.rdkit_hover\",r.prototype.default_view=_,r.define((({Bool:A,Dict:e,Unknown:o})=>({prefer_coordgen:[A,!0],remove_hs:[A,!0],sanitize:[A,!0],kekulize:[A,!0],draw_options:[e(o),{}]}))),r.register_alias(\"rdkit_hover\",(()=>new r))}\n//# sourceMappingURL=rdkit_hover.min.js.map","min_map":"{\"version\":3,\"file\":\"rdkit_hover.min.js\",\"names\":[\"_\",\"require\",\"module\",\"exports\",\"__esModule\",\"__esExport\",\"_a\",\"base_hover_1\",\"rdkit_formatter_1\",\"RDKitHoverView\",\"BaseHoverView\",\"initialize\",\"super\",\"formatters\",\"smiles_column\",\"width\",\"height\",\"mols_per_row\",\"prefer_coordgen\",\"remove_hs\",\"sanitize\",\"kekulize\",\"draw_options\",\"this\",\"model\",\"RDKitFormatter\",\"__name__\",\"RDKitHover\",\"BaseHover\",\"computed_icon\",\"constructor\",\"attrs\",\"tool_name\",\"__module__\",\"prototype\",\"default_view\",\"define\",\"Bool\",\"Dict\",\"Unknown\",\"register_alias\"],\"sources\":[\"0\"],\"mappings\":\"AAA4B,SAASA,EAAEC,EAASC,EAAQC,EAASC,EAAYC,GACzE,IAAIC,EACJF,IACA,MAAMG,EAAeN,EAAQ,cACvBO,EAAoBP,EAAQ,cAClC,MAAMQ,UAAuBF,EAAaG,cACtC,UAAAC,GACIC,MAAMD,aACN,MAAME,WAAEA,EAAUC,cAAEA,EAAaC,MAAEA,EAAKC,OAAEA,EAAMC,aAAEA,EAAYC,gBAAEA,EAAeC,UAAEA,EAASC,SAAEA,EAAQC,SAAEA,EAAQC,aAAEA,GAAiBC,KAAKC,MAEtIX,EAAW,IAAMC,GAAiB,IAAIN,EAAkBiB,eAAe,CACnEV,MAAOA,EACPC,OAAQA,EACRC,aAAcA,EACdC,gBAAiBA,EACjBC,UAAWA,EACXC,SAAUA,EACVC,SAAUA,EACVC,aAAcA,GAEtB,EAEJnB,EAAQM,eAAiBA,EACzBA,EAAeiB,SAAW,iBAC1B,MAAMC,UAAmBpB,EAAaqB,UAClC,iBAAIC,GACA,MAAO,ofACX,CACA,WAAAC,CAAYC,GACRnB,MAAMmB,GACNR,KAAKS,UAAY,aACrB,EAEJ7B,EAAQwB,WAAaA,EACrBrB,EAAKqB,EACLA,EAAWD,SAAW,aACtBC,EAAWM,WAAa,8BAEpB3B,EAAG4B,UAAUC,aAAe1B,EAC5BH,EAAG8B,QAAO,EAAGC,OAAMC,OAAMC,cAAc,CACnCrB,gBAAiB,CAACmB,GAAM,GACxBlB,UAAW,CAACkB,GAAM,GAClBjB,SAAU,CAACiB,GAAM,GACjBhB,SAAU,CAACgB,GAAM,GACjBf,aAAc,CAACgB,EAAKC,GAAU,CAAC,OAEnCjC,EAAGkC,eAAe,eAAe,IAAM,IAAIlC,GAEnD\",\"ignoreList\":[]}"}},{"module":{"file":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib/models/smilesdrawer_formatter.js","base":"/home/runner/work/bokehmol/bokehmol/bokehmol/dist/lib","base_path":"models/smilesdrawer_formatter.js","canonical":"models/smilesdrawer_formatter","resolution":"ESM","id":"be6f45e05e","hash":"be6f45e05e0e105f52ee7179e5e93723294e1d2eb4201e1c065b9bbded877663","source":"\"use strict\";\nvar _a;\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.SmilesDrawerFormatter = void 0;\nconst base_formatter_1 = require(\"./base_formatter\");\nclass SmilesDrawerFormatter extends base_formatter_1.BaseFormatter {\n constructor(attrs) {\n super(attrs);\n }\n initialize() {\n super.initialize();\n this.onSmiDrawerReady(true, false, () => {\n // @ts-expect-error\n this.SmiDrawer = SmiDrawer;\n });\n }\n onSmiDrawerReady(init, lib, callback) {\n this.hasLoadedSmiDrawer(init, lib) ? callback() : setTimeout(() => {\n this.onSmiDrawerReady(init, lib, callback);\n }, 100);\n }\n hasLoadedSmiDrawe