Skip to content

feat: add compound html timerange component#14

Merged
luwes merged 2 commits intomainfrom
timerange-html
Sep 18, 2025
Merged

feat: add compound html timerange component#14
luwes merged 2 commits intomainfrom
timerange-html

Conversation

@luwes
Copy link
Copy Markdown
Collaborator

@luwes luwes commented Sep 15, 2025

No description provided.

state: TState
) => React.ReactElement;

const Context = React.createContext<any | null>(null);
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

non-blocking: If there's an easy way to make this optional, that would be 👌. Feel free to e.g. change the args into an "options-style object" if that makes things easier.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cool yes, that a nice optimization. I'll leave it for a next iteration.


export const useTimeRangeTrackProps = (props: React.PropsWithChildren<{ [k: string]: any }>) => {
const { setTrackRef } = useTimeRangeRootContext();
export const useTimeRangeTrackProps = (props: React.PropsWithChildren<{ [k: string]: any }>, context: any) => {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question(non-blocking) - is this "context" or the context's "value"?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the context value
const context = React.useContext(Context);

bad naming on my part

@luwes luwes changed the title fix: add context logic to component factory feat: add compound html timerange component Sep 18, 2025
@luwes luwes marked this pull request as ready for review September 18, 2025 15:57
@luwes luwes merged commit 017ecdb into main Sep 18, 2025
@luwes luwes deleted the timerange-html branch September 18, 2025 22:58
@github-actions github-actions bot mentioned this pull request Oct 24, 2025
@github-actions github-actions bot mentioned this pull request Feb 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants