repo
stringlengths
7
64
file_url
stringlengths
81
338
file_path
stringlengths
5
257
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:25:31
2026-01-05 01:50:38
truncated
bool
2 classes
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/scaffolds/post-edit-page.tsx
packages/app-cms-posts/scaffolds/post-edit-page.tsx
import React, { useState, useEffect } from "react"; import Dialog from "@material-ui/core/Dialog"; import { useRouter } from "next/router"; import { BoringScaffold } from "@grida.co/app/boring-scaffold"; import { PublishPostReviewDialogBody } from "../dialogs"; import { PostsClient } from "../api"; import { BoringDocum...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/scaffolds/posts-page.tsx
packages/app-cms-posts/scaffolds/posts-page.tsx
import React, { useEffect, useState } from "react"; import styled from "@emotion/styled"; import { PostListItem, PostsTableToolBar } from "../components"; import { InBlockButton } from "@app/blocks"; import { PostsAppThemeProvider } from "../theme"; import type { Post, Publication } from "../types"; import type { Theme...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/scaffolds/index.ts
packages/app-cms-posts/scaffolds/index.ts
export { default as TablePage } from "./posts-page"; export { default as EditPage } from "./post-edit-page";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/utils/summarize.ts
packages/app-cms-posts/utils/summarize.ts
/** * get the summary from the body html. * * * e.g. from * ```html * <p><b>SERVES: 1</b></p> * <p>Legend has it that the Ice Cream Float was invented on a particularly hot Philadelphia day by a soda vendor who had run out of ice. To cool his drinks</p> * ``` * * => returns the second paragraph * * * @para...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/utils/index.ts
packages/app-cms-posts/utils/index.ts
export * from "./summarize";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/api/index.ts
packages/app-cms-posts/api/index.ts
import Axios, { AxiosInstance } from "axios"; import type { Post, Publication } from "../types"; import assert from "assert"; export class PostsClient { private _client: AxiosInstance; constructor(readonly publicationId: string) { this._client = Axios.create({ baseURL: "https://posts.grida.cc", }); ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/types/index.ts
packages/app-cms-posts/types/index.ts
export interface Post { id: string; title: string; displayTitle?: string; summary?: string; thumbnail?: string; author?: any; // TODO: body: any; isDraft: boolean; isListed: boolean; tags?: string[]; scheduledAt?: string | Date; postedAt?: string | Date; createdAt?: string | Date; lastEditAt...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/layouts/contents.tsx
packages/app-cms-posts/layouts/contents.tsx
import React from "react"; import styled from "@emotion/styled"; export function ContentsLayout({ children }: { children: React.ReactNode }) { return <Container>{children}</Container>; } const Container = styled.div` width: 100%; `;
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/layouts/cover.tsx
packages/app-cms-posts/layouts/cover.tsx
import React from "react"; import styled from "@emotion/styled"; export function CoverLayout({ src }: { src?: string }) { return ( <Container> { // src ? <CoverImage width={"100%"} height={"100%"} src={src} /> : <></> } </Container> ); } const Container = styled.div` position...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/layouts/index.ts
packages/app-cms-posts/layouts/index.ts
export { CoverLayout } from "./cover"; export { IconLayout } from "./icon"; export { ContentsLayout } from "./contents"; export { TitleLayout } from "./title";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/layouts/icon.tsx
packages/app-cms-posts/layouts/icon.tsx
import React from "react"; import styled from "@emotion/styled"; export function IconLayout({ src }: { src?: string }) { return ( <Container> { // src ? <IconImage src={src} /> : <></> } </Container> ); } const Container = styled.div` position: relative; max-width: 150px; ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/layouts/title.tsx
packages/app-cms-posts/layouts/title.tsx
import React from "react"; import styled from "@emotion/styled"; export function TitleLayout({ children }: { children: React.ReactNode }) { return ( <Title> {/* */} {children} </Title> ); } const Title = styled.span` cursor: default; color: rgb(26, 26, 26); text-overflow: ellipsis; fo...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/dialogs/index.ts
packages/app-cms-posts/dialogs/index.ts
export { PublishPostReviewDialogBody } from "./publish-post-review-dialog"; export { DeletePostConfirmAlertDialog } from "./delete-post-confirm-alert-dialog";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/dialogs/delete-post-confirm-alert-dialog/index.tsx
packages/app-cms-posts/dialogs/delete-post-confirm-alert-dialog/index.tsx
import React, { useState } from "react"; import { AlertDialog, AlertDialogContent, AlertDialogTitle, AlertDialogDescription, AlertDialogCancel, AlertDialogAction, AlertDialogPrimitive, AlertDialogOverlay, } from "@editor-ui/alert-dialog"; import styled from "@emotion/styled"; import Dialog from "@materi...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/dialogs/publish-post-review-dialog/index.tsx
packages/app-cms-posts/dialogs/publish-post-review-dialog/index.tsx
import React, { useState } from "react"; import styled from "@emotion/styled"; import { EditSummarySegment } from "./edit-summary"; import { EditThumbnailSegment } from "./edit-thumbnail"; import { EditTagsSegment } from "./edit-tags"; import { RoundPrimaryButton } from "../../components"; import { DatePicker } from "@...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/dialogs/publish-post-review-dialog/edit-thumbnail.tsx
packages/app-cms-posts/dialogs/publish-post-review-dialog/edit-thumbnail.tsx
import React, { useRef, useState } from "react"; import styled from "@emotion/styled"; import { ThumbnailView } from "./edit-thumbnail-view"; export function EditThumbnailSegment({ onFileUpload, initialThumbnail, }: { /** * handle file * ```ts * let data = new FormData(); * data.append("file", file); ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/dialogs/publish-post-review-dialog/edit-thumbnail-view.tsx
packages/app-cms-posts/dialogs/publish-post-review-dialog/edit-thumbnail-view.tsx
import React from "react"; import styled from "@emotion/styled"; export function ThumbnailView({ src, label, onClick, loading, }: { src?: string; label?: string; onClick?: () => void; loading?: boolean; // }) { return ( <Container loading={loading}> {src && <Src src={src} />} {label...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/dialogs/publish-post-review-dialog/edit-summary.tsx
packages/app-cms-posts/dialogs/publish-post-review-dialog/edit-summary.tsx
import React from "react"; import styled from "@emotion/styled"; import css from "@emotion/css"; import TextareaAutosize from "react-textarea-autosize"; export function EditSummarySegment({ title, summary, onTitleChange, onSummaryChange, }: { title; summary: string; onTitleChange: (title: string) => void...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/dialogs/publish-post-review-dialog/edit-schedule.tsx
packages/app-cms-posts/dialogs/publish-post-review-dialog/edit-schedule.tsx
import React from "react"; export function EditScheduleSegment() { // TODO: migrate from main dialog return <></>; }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/dialogs/publish-post-review-dialog/edit-tags.tsx
packages/app-cms-posts/dialogs/publish-post-review-dialog/edit-tags.tsx
import React from "react"; import styled from "@emotion/styled"; import { TagsInput } from "@ui/tags-input"; export function EditTagsSegment({ tags, onChange, }: { tags: Array<string>; onChange: (tags: Array<string>) => void; }) { return ( <TagsEditContainer> <AddTagsForReadersUpTo5>Add tags for se...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/theme/index.tsx
packages/app-cms-posts/theme/index.tsx
import { ThemeProvider } from "@emotion/react"; import styled, { CreateStyled } from "@emotion/styled"; import { Theme as EditorTheme, useTheme } from "@editor-ui/theme"; // import "@emotion/react"; interface _Theme { app_posts_cms: { colors: { root_background: React.CSSProperties["color"]; button_pr...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/urls/url-on-publication.ts
packages/app-cms-posts/urls/url-on-publication.ts
import type { PublicationHost } from "../types"; import UrlPattern from "url-pattern"; type PostOnPublicationViewUrlParams = { id: string; }; export function buildViewPostOnPublicationUrl( host: PublicationHost, params: PostOnPublicationViewUrlParams, preview?: boolean ) { const { homepage, pattern } = host...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/urls/index.ts
packages/app-cms-posts/urls/index.ts
export * from "./url-on-publication";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-cms-posts/_dev/mock-data.ts
packages/app-cms-posts/_dev/mock-data.ts
export const __grida_blog_dummy_posts = [ { id: "1", title: "Introducing Grida Posts", summary: "Grida posts is a new way of managing your posts, blogs and newspresses. Write, publish customize your posts without leaving Grida. Comes with headless CMS and SDK for your custom needs", autor: "univ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/directory-card-block.tsx
packages/app-blocks/directory-card-block.tsx
import React from "react"; export function DirectoryCard() { return <></>; }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/index.ts
packages/app-blocks/index.ts
export * from "./in-block-button"; export * from "./scaffold-code-block"; export * from "./screen-preview-card-block"; export * from "./table-tab-item"; export * from "./content-card-block"; export * from "./directory-card-block";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/content-card-block.tsx
packages/app-blocks/content-card-block.tsx
import React from "react"; import styled from "@emotion/styled"; import { nanoid } from "nanoid"; export function ContentCard(props: { id?: string; title: string; description: string; }) { let key = props.id ?? nanoid(); return <Root key={key}>{props.title}</Root>; } const Root = styled.div``;
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/screen-preview-card-block/provider-sketch-embed.tsx
packages/app-blocks/screen-preview-card-block/provider-sketch-embed.tsx
import React from "react"; interface ProviderSketchEmbedProps { url: string; } export function ProviderSketchEmbed(props: ProviderSketchEmbedProps) { return <>SKETCH EMBED</>; }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/screen-preview-card-block/provider-any-snapshot-view.tsx
packages/app-blocks/screen-preview-card-block/provider-any-snapshot-view.tsx
import React from "react"; interface ProviderAnySnapshotViewProps { /** * snapshot image file uri */ snapshot: string; } export function ProviderAnySnapshotView(props: ProviderAnySnapshotViewProps) { return ( <> <img src={props.snapshot} /> </> ); }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/screen-preview-card-block/screen-preview-card-block.tsx
packages/app-blocks/screen-preview-card-block/screen-preview-card-block.tsx
import React from "react"; import styled from "@emotion/styled"; import { ProviderFigmaEmbed } from "./provider-figma-embed"; import { ProviderAnySnapshotView } from "./provider-any-snapshot-view"; import { ProviderSketchEmbed } from "./provider-sketch-embed"; import { ProviderUnknownIframeEmbed } from "./provider-unkn...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/screen-preview-card-block/provider-figma-embed.tsx
packages/app-blocks/screen-preview-card-block/provider-figma-embed.tsx
import React from "react"; import FigmaEmbed from "@reflect-blocks/figma-embed"; interface ProviderFigmaEmbedProps { url: string; } export function ProviderFigmaEmbed(props: ProviderFigmaEmbedProps) { return ( <> <FigmaEmbed src={props.url} width="315px" height="712px" /> </> ); }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/screen-preview-card-block/provider-unknown-iframe-embed.tsx
packages/app-blocks/screen-preview-card-block/provider-unknown-iframe-embed.tsx
import React from "react"; interface ProviderUnknownIframeEmbedProps { url: string; } export function ProviderUnknownIframeEmbed( props: ProviderUnknownIframeEmbedProps ) { return ( <> <iframe src={props.url} /> </> ); }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/screen-preview-card-block/provider-nothing-embed.tsx
packages/app-blocks/screen-preview-card-block/provider-nothing-embed.tsx
import React from "react"; interface ProviderNothingEmbedProps {} export function ProviderNothingEmbed(props: ProviderNothingEmbedProps) { return <></>; }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/screen-preview-card-block/index.ts
packages/app-blocks/screen-preview-card-block/index.ts
export * from "./screen-preview-card-block"; // do not export others - kepp it clean
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/in-block-button/in-block-button.tsx
packages/app-blocks/in-block-button/in-block-button.tsx
import React from "react"; import styled from "@emotion/styled"; export function InBlockButton({ icon, children, onClick, href, }: { icon?: React.ReactNode; children: React.ReactNode; onClick?: () => void; href?: string; }) { return ( <Container onClick={onClick} href={href}> {icon ? <IconC...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/in-block-button/index.ts
packages/app-blocks/in-block-button/index.ts
export { InBlockButton } from "./in-block-button";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/scaffold-code-block/scaffold-code-block.tsx
packages/app-blocks/scaffold-code-block/scaffold-code-block.tsx
import React, { useState, useEffect } from "react"; import styled from "@emotion/styled"; import { format } from "@base-sdk/functions-code-format"; import Editor, { useMonaco } from "@monaco-editor/react"; export interface ScaffoldCodeBlockProps { source: string; lang: "html" | "ts" | "js" | "dart"; } const monaco...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/scaffold-code-block/index.ts
packages/app-blocks/scaffold-code-block/index.ts
export * from "./scaffold-code-block";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/bookmark-block/index.ts
packages/app-blocks/bookmark-block/index.ts
export { BookmarkBlock, BaseBookmarkBlock } from "./bookmark-block";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/bookmark-block/bookmark-block.tsx
packages/app-blocks/bookmark-block/bookmark-block.tsx
import React from "react"; import styled from "@emotion/styled"; export function BookmarkBlock({ url }: { url: string }) { // 1. fetch url data // TODO: return <BaseBookmarkBlock loading url={url} favicon={url + "/favicon.ico"} />; } export function BaseBookmarkBlock({ title, description, url, favicon, ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/table-tab-item/index.ts
packages/app-blocks/table-tab-item/index.ts
export { TableTabItem } from "./table-tab-item";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-blocks/table-tab-item/table-tab-item.tsx
packages/app-blocks/table-tab-item/table-tab-item.tsx
import React from "react"; import styled from "@emotion/styled"; export function TableTabItem({ icon, children = <>Tab Item</>, selected = false, badge = null, onClick, }: { icon?: React.ReactNode; /** * label */ children: React.ReactNode; selected?: boolean; badge?: string | number; onClic...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-fp-customer-support/index.ts
packages/app-fp-customer-support/index.ts
export { ChatwootWidget, Chatwoot } from "./chatwoot"; export { GlobalHelpButton } from "./global-help-button";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-fp-customer-support/global-help-button/help-button.tsx
packages/app-fp-customer-support/global-help-button/help-button.tsx
import React from "react"; import styled from "@emotion/styled"; import { Chatwoot, ChatwootWidget } from "../chatwoot"; import { DropdownMenu, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuItem, DropdownMenuArrow, } from "@editor-ui/dropdown-menu"; export function GlobalHelpButton() { return ( ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-fp-customer-support/global-help-button/index.ts
packages/app-fp-customer-support/global-help-button/index.ts
export { GlobalHelpButton } from "./help-button";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-fp-customer-support/chatwoot/widget.tsx
packages/app-fp-customer-support/chatwoot/widget.tsx
/// /// https://www.chatwoot.com/docs/product/channels/live-chat/sdk/setup /// import React from "react"; import "./types"; /** * https://www.chatwoot.com/docs/product/channels/live-chat/integrations/nextjs */ export class ChatwootWidget extends React.Component<{ /** * rather to show chat bubble initially *...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-fp-customer-support/chatwoot/sdk.ts
packages/app-fp-customer-support/chatwoot/sdk.ts
import "./types"; export namespace Chatwoot { export function toggle(state?: "open" | "close") { window.$chatwoot.toggle(state); } export function reset() { window.$chatwoot.reset(); } export function setLabel(label: string) { window.$chatwoot.setLabel(label); } export function removeLabel(...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-fp-customer-support/chatwoot/types.ts
packages/app-fp-customer-support/chatwoot/types.ts
export interface ChatwootSetUserProps { name?: string; // Name of the user avatar_url?: string; // Avatar URL email?: string; // Email of the user identifier_hash?: string; // Identifier Hash generated based on the webwidget hmac_token phone_number?: string; // Phone Number of the user description?: string;...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/app-fp-customer-support/chatwoot/index.ts
packages/app-fp-customer-support/chatwoot/index.ts
export { ChatwootWidget } from "./widget"; export { Chatwoot } from "./sdk";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/icons-locale/lang-icon-jp.tsx
packages/icons-locale/lang-icon-jp.tsx
import React from 'react'; const LangIconEn = () => ( <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M9.99 0C4.47 0 0 4.48 0 10C0 15.52 4.47 20 9.99 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 9.99 0ZM16.92 6H13.97C13.65 4.75 1...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/icons-locale/lang-icon-en.tsx
packages/icons-locale/lang-icon-en.tsx
import React from 'react'; const LangIconEn = () => ( <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M9.99 0C4.47 0 0 4.48 0 10C0 15.52 4.47 20 9.99 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 9.99 0ZM16.92 6H13.97C13.65 4.75 1...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/icons-locale/lang-icon-kr.tsx
packages/icons-locale/lang-icon-kr.tsx
import React from 'react'; const LangIconKr = () => ( <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M9.99 0C4.47 0 0 4.48 0 10C0 15.52 4.47 20 9.99 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 9.99 0ZM16.92 6H13.97C13.65 4.75 1...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/index.ts
packages/core-app-state/index.ts
export * from "./application-state"; export * from "./global-input-blur"; export * from "./dispatch"; export * from "./state-provider"; export * from "./workspace-state"; export * as hooks from "./use-states";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/use-states/use-current-page.ts
packages/core-app-state/use-states/use-current-page.ts
import { useState, useEffect } from "react"; import { PageStore } from "@core/store"; import { useApplicationState } from "../application-state"; import { Page } from "@core/model"; export function useCurrentPage() { const [page, setPage] = useState<Page>(); const [app] = useApplicationState(); const _pageid = a...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/use-states/index.ts
packages/core-app-state/use-states/index.ts
export * from "./use-current-page";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/global-input-blur/global-input-blur.ts
packages/core-app-state/global-input-blur/global-input-blur.ts
import { createContext, useContext, useEffect } from "react"; export type GlobalInputBlurContextValue = { addListener: (f: () => void) => void; removeListener: (f: () => void) => void; trigger: () => void; }; const defaultValue = (() => { const listeners: (() => void)[] = []; const value: GlobalInputBlurCo...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/global-input-blur/index.ts
packages/core-app-state/global-input-blur/index.ts
export * from "./global-input-blur";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/dispatch/index.ts
packages/core-app-state/dispatch/index.ts
export * from "./use-dispatch"; export * from "./dispatchers";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/dispatch/use-dispatch.ts
packages/core-app-state/dispatch/use-dispatch.ts
import { useGlobalInputBlurTrigger } from "../global-input-blur"; import { Action } from "@core/state"; import { createContext, useCallback, useContext } from "react"; import { noop } from "../_utils"; export type Dispatcher = (action: Action) => void; export type FlatDispatcher = (action: Action) => void; export co...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/dispatch/dispatchers/add-page.ts
packages/core-app-state/dispatch/dispatchers/add-page.ts
import { IAddPageAction } from "../../../core-state"; import { useDispatch } from "../use-dispatch"; export function useAddPage() { const dispatch = useDispatch(); return (p: IAddPageAction) => dispatch({ type: "add-page", ...p, }); }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/dispatch/dispatchers/index.ts
packages/core-app-state/dispatch/dispatchers/index.ts
export * from "./add-page";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/boring-state/index.ts
packages/core-app-state/boring-state/index.ts
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/boring-state/use-boring-state.ts
packages/core-app-state/boring-state/use-boring-state.ts
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/state-provider/state-provider.tsx
packages/core-app-state/state-provider/state-provider.tsx
import React, { memo, ReactNode } from "react"; import { Dispatcher, DispatchContext } from "../dispatch"; import { noop } from "../_utils"; import { StateContext } from "../workspace-state"; import { WorkspaceState } from "@core/state"; export const StateProvider = memo(function StateProvider({ state, dispatch, ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/state-provider/index.ts
packages/core-app-state/state-provider/index.ts
export * from "./state-provider";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/application-state/use-application-state.ts
packages/core-app-state/application-state/use-application-state.ts
import { useMemo } from "react"; import { ApplicationState } from "@core/state"; import { useWorkspaceState } from "../workspace-state"; import { useDispatch, FlatDispatcher } from "../dispatch"; export const useApplicationState = (): [ApplicationState, FlatDispatcher] => { const state = useWorkspaceState(); const...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/application-state/index.ts
packages/core-app-state/application-state/index.ts
export * from "./use-application-state";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/_utils/index.ts
packages/core-app-state/_utils/index.ts
export * from "./noop";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/_utils/noop.ts
packages/core-app-state/_utils/noop.ts
export const noop = () => {};
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/workspace-state/state-context.ts
packages/core-app-state/workspace-state/state-context.ts
import { createContext } from "react"; import { WorkspaceState } from "@core/state"; export const StateContext = createContext<WorkspaceState | undefined>( undefined );
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/workspace-state/use-workspace-state.ts
packages/core-app-state/workspace-state/use-workspace-state.ts
import { useContext, createContext } from "react"; import { WorkspaceState } from "@core/state"; import { StateContext } from "./state-context"; export const useWorkspaceState = (): WorkspaceState => { const value = useContext(StateContext); // If this happens, we'll conditionally call hooks afterward // TODO: ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-app-state/workspace-state/index.ts
packages/core-app-state/workspace-state/index.ts
export * from "./state-context"; export * from "./use-workspace-state";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-model/index.ts
packages/core-model/index.ts
export * from "./page"; export * from "./workspace";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-model/workspace/workspace-model.ts
packages/core-model/workspace/workspace-model.ts
/** * workspace model. referenced by @WorkspaceState */ export interface Workspace { preferences: { // add preference here }; }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-model/workspace/index.ts
packages/core-model/workspace/index.ts
export * from "./workspace-model";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-model/page/index.ts
packages/core-model/page/index.ts
export * from "./page-model";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-model/page/page-model.ts
packages/core-model/page/page-model.ts
import { BoringDocument } from "@boring.so/document-model"; import { PageParentId, PageRoot, PageRootKey } from "@core/state"; export type PageId = string; export interface PageReference extends IPageHierarchyReference { id: PageId; type: "boring-document" | "nothing-document"; name: string; parent?: string; ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/lib/treearray/nest.ts
packages/lib/treearray/nest.ts
// type KeyMatcherLike = (item, item) => boolean | null; /** * from - https://stackoverflow.com/a/55241491/5463235 * @param items * @param id * @param link * @returns */ export function nest( items: any[], id = null, link = "parent", sort: (a, b) => number = (a, b) => 0, depth = 0 ) { return items ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/lib/treearray/sortable.ts
packages/lib/treearray/sortable.ts
import type { IIdentifier } from "./identifier"; type Key = string; type ParentKey = Key; export interface ISortGroup extends IIdentifier { id: string; // as in id of this group. (parent) children: ISortItem[]; } export interface ISortItem extends IIdentifier { id: string; sort: number; } export interface T...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/lib/treearray/treearray.ts
packages/lib/treearray/treearray.ts
import { nest } from "./nest"; import { movementDiff } from "./movement-diff"; import { reject_parent_moving_inner } from "./validators"; import { TreeNodeWithUnevenSortDataArrayItem } from "./sortable"; type IDeepTreeItemLike = { children: IDeepTreeItemLike[]; }; export class TreeArray< T extends TreeNodeWithUne...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/lib/treearray/identifier.ts
packages/lib/treearray/identifier.ts
export interface IIdentifier { id: string; }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/lib/treearray/index.ts
packages/lib/treearray/index.ts
export * from "./treearray"; export * from "./identifier"; export * from "./movement-diff"; export * from "./sortable"; export * from "./nest";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/lib/treearray/movement-diff.ts
packages/lib/treearray/movement-diff.ts
import type { IIdentifier } from "./identifier"; import type { ISortGroup, ISortItem } from "./sortable"; export function movementDiff({ item, prevgroup, postgroup, prevorder, postorder, options = { bigstep: 1, smallstep: 1, }, }: { item: IIdentifier; prevgroup: ISortGroup; postgroup: ISort...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/lib/treearray/validators/reject-parent-moving-inner.ts
packages/lib/treearray/validators/reject-parent-moving-inner.ts
import { TreeNodeWithUnevenSortDataArrayItem } from "../sortable"; type TreeNodeWithUnevenSortDataArrayItemWithDepth = TreeNodeWithUnevenSortDataArrayItem & { depth: number; }; /** * reject the movement of the parent to it's children's or its' inner * * prevent "parent" to move anywhere under "parent" * *...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/lib/treearray/validators/index.ts
packages/lib/treearray/validators/index.ts
export * from "./reject-parent-moving-inner";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/lib/treearray/__tests__/movement.test.ts
packages/lib/treearray/__tests__/movement.test.ts
import { __insert } from "../index"; test("insert on last", () => { const test = __insert({ step: { big: 1000, }, insert: { id: "new" }, insertat: 10, data: [ { id: "0", sort: 1 }, // 2 { id: "1", sort: 2 }, // 3 { id: "2", sort: 3 }, // 4 { id: "3", sort: 1000 }, // ...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/lib/treearray/__tests__/treearray.test.ts
packages/lib/treearray/__tests__/treearray.test.ts
import { TreeArray } from "../treearray"; const ta = new TreeArray( [ { id: "1", sort: 1, parent: "root", }, { id: "2", sort: 0, parent: "root", }, { id: "1-1", sort: 2, parent: "1", }, { id: "1-1-1", sort: 100, paren...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-events/lib/index.ts
packages/core-events/lib/index.ts
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-events/lib/_i/index.ts
packages/core-events/lib/_i/index.ts
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-events/lib/_o/index.ts
packages/core-events/lib/_o/index.ts
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-state/index.ts
packages/core-state/index.ts
export * from "./action"; // export * from "./application"; export * from "./workspace"; // export * from "./page";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-state/action/index.ts
packages/core-state/action/index.ts
import { PageAction } from "../page/page-action"; export type WorkspaceAction = | { type: "newFile" } // | HistoryAction; export type HistoryAction = // | { type: "undo" } // | { type: "redo" } | Action; export type Action = // PageAction; export type ActionType = Action["type"];
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-state/workspace/workspace-reducer.ts
packages/core-state/workspace/workspace-reducer.ts
import produce from "immer"; import { WorkspaceState } from "./workspace-state"; import { WorkspaceAction } from "../action"; import { createInitialHistoryState, historyReducer } from "../history"; export function workspaceReducer( state: WorkspaceState, action: WorkspaceAction ): WorkspaceState { switch (action...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-state/workspace/create-initial-workspace-state.ts
packages/core-state/workspace/create-initial-workspace-state.ts
import { ApplicationSnapshot } from "../application"; import { createInitialHistoryState } from "../history"; import { WorkspaceState } from "./workspace-state"; export function createInitialWorkspaceState( app: ApplicationSnapshot ): WorkspaceState { return { history: createInitialHistoryState(app), prefe...
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-state/workspace/workspace-state.ts
packages/core-state/workspace/workspace-state.ts
import { HistoryState } from "../history"; import { Workspace } from "@core/model"; export interface WorkspaceState extends Workspace { history: HistoryState; }
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-state/workspace/index.ts
packages/core-state/workspace/index.ts
export * from "./workspace-state"; export * from "./workspace-reducer"; export * from "./create-initial-workspace-state";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-state/boring/boring-reducer.ts
packages/core-state/boring/boring-reducer.ts
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-state/boring/boring-selector.ts
packages/core-state/boring/boring-selector.ts
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-state/boring/boring-action.ts
packages/core-state/boring/boring-action.ts
export * from "@boring.so/action";
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false
gridaco/legacy
https://github.com/gridaco/legacy/blob/8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582/packages/core-state/boring/index.ts
packages/core-state/boring/index.ts
typescript
Apache-2.0
8fc8b1fb2f3e4419eeaa49193ddb5c1fade82582
2026-01-05T05:01:14.213250Z
false