diff --git a/frontend/src/metabase/browse/components/utils.tsx b/frontend/src/metabase/browse/components/utils.tsx index f88304d642c5848279f9fffac693028b444c6423..3f83dae39a92ec1a244b26c4e7ca197d70dcc2cc 100644 --- a/frontend/src/metabase/browse/components/utils.tsx +++ b/frontend/src/metabase/browse/components/utils.tsx @@ -8,30 +8,6 @@ import { getCollectionName } from "../utils"; import { pathSeparatorChar } from "./constants"; -export const getBreadcrumbMaxWidths = ( - collections: CollectionEssentials["effective_ancestors"], - totalUnitsOfWidthAvailable: number, - isPathEllipsified: boolean, -) => { - if (!collections || collections.length < 2) { - return []; - } - const lengths = collections.map( - collection => getCollectionName(collection).length, - ); - const ratio = lengths[0] / (lengths[0] + lengths[1]); - const firstWidth = Math.max( - Math.round(ratio * totalUnitsOfWidthAvailable), - 25, - ); - const secondWidth = totalUnitsOfWidthAvailable - firstWidth; - const padding = isPathEllipsified ? "2rem" : "1rem"; - return [ - `calc(${firstWidth}cqw - ${padding})`, - `calc(${secondWidth}cqw - ${padding})`, - ]; -}; - export const isModel = (item: SearchResult) => item.model === "dataset"; export const getModelDescription = (item: SearchResult) => {