Skip to content

Commit

Permalink
Merge pull request #2454 from coingaming/MDS-722
Browse files Browse the repository at this point in the history
fix: add Loader to Docs, align colours [MDS-722]
  • Loading branch information
dkireev authored Oct 31, 2023
2 parents 699f81c + 7e31ad1 commit fbefb96
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/app/components/server/loader/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Loaders provide a visual cue that an action is processing awaiting a course of change or a result.
5 changes: 5 additions & 0 deletions docs/app/components/server/loader/examples/Default.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import Loader from '@heathmont/moon-base-tw/lib/loader/Loader';

export const Default = () => <Loader />;

export default Default;
22 changes: 22 additions & 0 deletions docs/app/components/server/loader/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import { Default } from '@/app/components/server/loader/examples/Default';
import ExampleSection from '@/app/components/shared/ExampleSection';
import QuickNav from '@/app/components/shared/QuickNav';
import { getExamples } from '@/app/utils/getExamples';
import { MDX } from '@/components/MDX';

export default async function Home() {
const { server } = await getExamples();
const examplesList = Object.keys(server.loader.examples);
return (
<div className="w-full max-w-7xl flex flex-col gap-4 text-moon-14">
<h1 className="font-medium text-moon-32">Loader</h1>
<MDX markdown={server.loader.description} />
<QuickNav items={examplesList} />
<ExampleSection
title="Default"
component={<Default />}
code={server.loader.examples.Default}
/>
</div>
);
}
6 changes: 6 additions & 0 deletions docs/app/components/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,12 @@ export interface Examples {
Default: 'string';
};
};
loader: {
description: 'string';
examples: {
Default: 'string';
};
};
tag: {
description: 'string';
examples: {
Expand Down

0 comments on commit fbefb96

Please sign in to comment.