Skip to content

Commit

Permalink
2021-07-13 1545
Browse files Browse the repository at this point in the history
  • Loading branch information
SkepticMystic committed Jul 13, 2021
1 parent 1fb4c6f commit 7ddd85b
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"build": "rollup -c --environment BUILD:production"
},
"keywords": [],
"author": "",
"author": "SkepticMystic",
"license": "MIT",
"devDependencies": {
"@rollup/plugin-commonjs": "^18.1.0",
Expand Down
6 changes: 3 additions & 3 deletions rollup.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import svelte from "rollup-plugin-svelte";
import resolve from "@rollup/plugin-node-resolve";
import commonjs from "@rollup/plugin-commonjs";
import resolve from "@rollup/plugin-node-resolve";
import typescript from "@rollup/plugin-typescript";
import autoPreprocess from "svelte-preprocess";
import { env } from "process";
import svelte from "rollup-plugin-svelte";
import autoPreprocess from "svelte-preprocess";

export default {
input: "src/main.ts",
Expand Down
4 changes: 3 additions & 1 deletion src/MatrixView.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
} from "src/constants";
import type { allGraphs, internalLinkObj, SquareProps } from "src/interfaces";
import type BreadcrumbsPlugin from "src/main";
import { closeImpliedLinks } from "src/sharedFunctions";
import { closeImpliedLinks, debug } from "src/sharedFunctions";
import Lists from "./Lists.svelte";
import Matrix from "./Matrix.svelte";

Expand Down Expand Up @@ -251,6 +251,8 @@ export default class MatrixView extends ItemView {
this.removeDuplicateImplied(realSiblings, impliedSiblingsArr);
this.removeDuplicateImplied(realChildren, impliedChildren);

debug(settings, { realParents, impliedParents, realSiblings, impliedSiblingsArr, realChildren, impliedChildren })

const parentsSquare: SquareProps = {
realItems: realParents,
impliedItems: impliedParents,
Expand Down
5 changes: 2 additions & 3 deletions src/sharedFunctions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -143,16 +143,15 @@ export function getFields(
superDebug(settings, `${field} (type: '${typeof fieldItems}') of: ${fileFrontmatter.file.basename} is:`)
// superDebug(settings, (fieldItems?.join(', ') ?? undefined))


const flattenedItems: string[] = ([fieldItems].flat(5)) as string[];
console.log(flattenedItems)
const flattenedItems: [] = ([fieldItems].flat(5));

const links: [] =
flattenedItems.map(
(link) => {
debug(settings, link);
return link?.path?.split("/").last() ?? (link?.split("/").last() ?? (''))
}) ?? [];
debug(settings, { links })
return links;
}
}
Expand Down

0 comments on commit 7ddd85b

Please sign in to comment.