Mercurial > repos > fubar > jbrowse2
diff x/static/js/5668.73016b9c.chunk.js.map @ 125:49f3d3878413 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/jbrowse2 commit 5ea1f9c1eef1de76232e69aa6d34cda77d90d566
author | fubar |
---|---|
date | Sat, 05 Oct 2024 23:58:05 +0000 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/x/static/js/5668.73016b9c.chunk.js.map Sat Oct 05 23:58:05 2024 +0000 @@ -0,0 +1,1 @@ +{"version":3,"file":"static/js/5668.73016b9c.chunk.js","mappings":"+OAIe,SAASA,GAAc,MACpCC,EAAK,OACLC,EAAM,MACNC,IAMA,MAAMC,GAAQC,EAAAA,EAAAA,KACd,OACEC,EAAAA,cAAA,QACEL,MAAOA,EAAgB,EAARE,EACfD,OAAQA,EACRK,MAAMC,EAAAA,EAAAA,YAAWJ,EAAMK,QAAQC,WAAWC,UAGhD,C,0BCAOC,eAAeC,EAAYC,EAAYC,GAC5C,MAAM,WACJC,EAAa,GAAE,aACfC,EAAe,GAAE,YACjBC,EAAc,GAAE,SAChBC,EAAW,GAAE,YACbC,EAAc,SAAQ,QACtBC,EAAUA,EAAGC,cAAeA,EAAQ,UACpCC,EAAY,WACVR,GAEE,aAAES,IAAiBC,EAAAA,EAAAA,SAAaX,GAChCY,GAAUC,EAAAA,EAAAA,YAAWb,GACrBV,EAAQsB,EAAQE,cAAcL,IAC9B,MAAEtB,EAAK,MAAE4B,GAAUf,EAEnBgB,EAASb,EAAeC,EACxBa,EAAUF,EAAMG,KACpBC,IAAKC,EAAAA,EAAAA,IAAYD,EAAEE,OAAQnB,EAAYI,GAAeU,IAElDM,GAAiBC,EAAAA,EAAAA,KAAIN,GAAW,IAChCO,QAAuBC,QAAQC,IACnCX,EAAMG,KACJpB,UAAU,CAEN6B,OACAC,WAAYH,QAAQC,IAClBC,EAAKN,OAAOH,KAAIpB,UACd,MAAM+B,EAAIC,EAAM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EAAAA,EAAO,CACNC,UAAW,CAAEC,QAAS,MACtBC,IAAK/C,EAAMa,cAAcS,QACzBpD,MAAOA,EACPoD,QAAStB,EAAMa,cAAcS,QAC7B0B,qBAAsBA,CAACR,EAAIS,IAAUhC,EAAagC,GAAQT,WAOtE5D,EAEJ,C","sources":["../../../plugins/breakpoint-split-view/src/BreakpointSplitView/svgcomponents/SVGBackground.tsx","../../../plugins/breakpoint-split-view/src/BreakpointSplitView/svgcomponents/SVGBreakpointSplitView.tsx","../../../plugins/breakpoint-split-view/src/BreakpointSplitView/svgcomponents/util.ts"],"sourcesContent":["import React from 'react'\nimport { useTheme } from '@mui/material'\nimport { stripAlpha } from '@jbrowse/core/util'\n\nexport default function SVGBackground({\n width,\n height,\n shift,\n}: {\n width: number\n height: number\n shift: number\n}) {\n const theme = useTheme()\n return (\n <rect\n width={width + shift * 2}\n height={height}\n fill={stripAlpha(theme.palette.background.default)}\n />\n )\n}\n","import React from 'react'\nimport { when } from 'mobx'\nimport { getSession, renderToStaticMarkup, sum } from '@jbrowse/core/util'\nimport { ThemeProvider } from '@mui/material'\nimport { createJBrowseTheme } from '@jbrowse/core/ui'\nimport { getRoot } from 'mobx-state-tree'\nimport {\n SVGTracks,\n SVGRuler,\n totalHeight,\n} from '@jbrowse/plugin-linear-genome-view'\n\n// locals\nimport SVGBackground from './SVGBackground'\nimport { ExportSvgOptions, BreakpointViewModel } from '../model'\nimport Overlay from '../components/Overlay'\nimport { getTrackNameMaxLen, getTrackOffsets } from './util'\n\ntype BSV = BreakpointViewModel\n\n// render LGV to SVG\nexport async function renderToSvg(model: BSV, opts: ExportSvgOptions) {\n const {\n textHeight = 18,\n headerHeight = 30,\n rulerHeight = 30,\n fontSize = 13,\n trackLabels = 'offset',\n Wrapper = ({ children }) => children,\n themeName = 'default',\n } = opts\n\n const { createRootFn } = getRoot<any>(model)\n const session = getSession(model)\n const theme = session.allThemes?.()[themeName]\n const { width, views } = model\n const shift = 50\n const offset = headerHeight + rulerHeight\n const heights = views.map(\n v => totalHeight(v.tracks, textHeight, trackLabels) + offset,\n )\n const totalHeightSvg = sum(heights) + 100\n const displayResults = await Promise.all(\n views.map(\n async view =>\n ({\n view,\n data: await Promise.all(\n view.tracks.map(async track => {\n const d = track.displays[0]\n await when(() => (d.ready !== undefined ? d.ready : true))\n return { track, result: await d.renderSvg({ ...opts, theme }) }\n }),\n ),\n }) as const,\n ),\n )\n\n const trackLabelMaxLen = getTrackNameMaxLen(views, fontSize, session) + 40\n const trackLabelOffset = trackLabels === 'left' ? trackLabelMaxLen : 0\n const textOffset = trackLabels === 'offset' ? textHeight : 0\n const trackOffsets = views.map((view, idx) =>\n getTrackOffsets(\n view,\n textOffset,\n fontSize + (idx > 0 ? heights[idx - 1]! : 0) + offset,\n ),\n )\n const w = width + trackLabelOffset\n const t = createJBrowseTheme(theme)\n\n // the xlink namespace is used for rendering <image> tag\n return renderToStaticMarkup(\n <ThemeProvider theme={t}>\n <Wrapper>\n <svg\n width={width}\n height={totalHeightSvg}\n xmlns=\"http://www.w3.org/2000/svg\"\n xmlnsXlink=\"http://www.w3.org/1999/xlink\"\n viewBox={[0, 0, w + shift * 2, totalHeightSvg].toString()}\n >\n <SVGBackground width={w} height={totalHeightSvg} shift={shift} />\n {views[0] ? (\n <g transform={`translate(${shift} ${fontSize})`}>\n <g transform={`translate(${trackLabelOffset})`}>\n <text x={0} fontSize={fontSize} fill={t.palette.text.primary}>\n {views[0].assemblyNames.join(', ')}\n </text>\n\n <SVGRuler model={displayResults[0]!.view} fontSize={fontSize} />\n </g>\n <SVGTracks\n textHeight={textHeight}\n trackLabels={trackLabels}\n fontSize={fontSize}\n model={displayResults[0]!.view}\n displayResults={displayResults[0]!.data}\n offset={offset}\n trackLabelOffset={trackLabelOffset}\n />\n </g>\n ) : null}\n\n {views[1] ? (\n <g transform={`translate(${shift} ${fontSize + heights[0]!})`}>\n <g transform={`translate(${trackLabelOffset})`}>\n <text x={0} fontSize={fontSize} fill={t.palette.text.primary}>\n {views[1].assemblyNames.join(', ')}\n </text>\n <SVGRuler model={displayResults[1]!.view} fontSize={fontSize} />\n </g>\n <SVGTracks\n textHeight={textHeight}\n trackLabels={trackLabels}\n fontSize={fontSize}\n model={displayResults[1]!.view}\n displayResults={displayResults[1]!.data}\n offset={offset}\n trackLabelOffset={trackLabelOffset}\n />\n </g>\n ) : null}\n\n <defs>\n <clipPath id=\"clip-bsv\">\n <rect x={0} y={0} width={width} height={totalHeightSvg} />\n </clipPath>\n </defs>\n <g\n transform={`translate(${trackLabelOffset + shift})`}\n clipPath=\"url(#clip-bsv)\"\n >\n {model.matchedTracks.map(track => (\n <Overlay\n parentRef={{ current: null }}\n key={track.configuration.trackId}\n model={model}\n trackId={track.configuration.trackId}\n getTrackYPosOverride={(id, level) => trackOffsets[level]![id]!}\n />\n ))}\n </g>\n </svg>\n </Wrapper>\n </ThemeProvider>,\n createRootFn,\n )\n}\n","import { AbstractSessionModel, max, measureText } from '@jbrowse/core/util'\n\n// locals\nimport { LinearGenomeViewModel } from '@jbrowse/plugin-linear-genome-view'\n\n// locals\nimport { getTrackName } from '@jbrowse/core/util/tracks'\n\nexport function getTrackNameMaxLen(\n views: LinearGenomeViewModel[],\n fontSize: number,\n session: AbstractSessionModel,\n) {\n return max(\n views.flatMap(view =>\n view.tracks.map(t =>\n measureText(getTrackName(t.configuration, session), fontSize),\n ),\n ),\n 0,\n )\n}\nexport function getTrackOffsets(\n view: LinearGenomeViewModel,\n textOffset: number,\n extra = 0,\n) {\n const offsets = {} as Record<string, number>\n let curr = textOffset\n for (const track of view.tracks) {\n offsets[track.configuration.trackId] = curr + extra\n curr += track.displays[0].height + textOffset\n }\n return offsets\n}\n"],"names":["SVGBackground","width","height","shift","theme","useTheme","React","fill","stripAlpha","palette","background","default","async","renderToSvg","model","opts","textHeight","headerHeight","rulerHeight","fontSize","trackLabels","Wrapper","children","themeName","createRootFn","getRoot","session","getSession","allThemes","views","offset","heights","map","v","totalHeight","tracks","totalHeightSvg","sum","displayResults","Promise","all","view","data","d","track","displays","when","undefined","ready","result","renderSvg","trackLabelMaxLen","max","flatMap","t","measureText","getTrackName","configuration","getTrackNameMaxLen","trackLabelOffset","textOffset","trackOffsets","idx","extra","offsets","curr","trackId","getTrackOffsets","w","createJBrowseTheme","renderToStaticMarkup","ThemeProvider","xmlns","xmlnsXlink","viewBox","toString","transform","x","text","primary","assemblyNames","join","SVGRuler","SVGTracks","id","y","clipPath","matchedTracks","Overlay","parentRef","current","key","getTrackYPosOverride","level"],"sourceRoot":""} \ No newline at end of file