Change links in multi-column mode so tabs are open in single-column mode (#25893)
This commit is contained in:
parent
41f65edb21
commit
5fad7bd58a
12 changed files with 77 additions and 19 deletions
|
@ -94,6 +94,13 @@ const element = document.getElementById('initial-state');
|
|||
/** @type {InitialState | undefined} */
|
||||
const initialState = element?.textContent && JSON.parse(element.textContent);
|
||||
|
||||
/** @type {string} */
|
||||
const initialPath = document.querySelector("head meta[name=initialPath]")?.getAttribute("content") ?? '';
|
||||
/** @type {boolean} */
|
||||
export const hasMultiColumnPath = initialPath === '/'
|
||||
|| initialPath === '/getting-started'
|
||||
|| initialPath.startsWith('/deck');
|
||||
|
||||
/**
|
||||
* @template {keyof InitialStateMeta} K
|
||||
* @param {K} prop
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue