Skip to content

Commit 7519a7e

Browse files
thetarnavgithub-actions[bot]
authored andcommitted
Format
1 parent 249bcf3 commit 7519a7e

File tree

274 files changed

+1392
-1392
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

274 files changed

+1392
-1392
lines changed

packages/active-element/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ clear();
7575
function makeFocusListener(
7676
target: Element,
7777
callback: (isActive: boolean) => void,
78-
useCapture?: boolean
78+
useCapture?: boolean,
7979
): VoidFunction;
8080
```
8181

packages/active-element/dev/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@ const Node: Component<{ x: number; y: number; size: number }> = props => {
1414
use:focus={setIsFocused}
1515
class="fixed top-0 left-0 w-48 h-48 rounded-full bg-orange-700 border-none cursor-pointer hover:bg-orange-600 text-4xl font-extrabold text-gray-900"
1616
classList={{
17-
"!bg-indigo-700 !hover:bg-indigo-600": isFocused()
17+
"!bg-indigo-700 !hover:bg-indigo-600": isFocused(),
1818
}}
1919
style={{
2020
transform: `translate(${props.x}px, ${props.y}px) scale(${props.size})`,
21-
transition: "transform 500ms, background 200ms"
21+
transition: "transform 500ms, background 200ms",
2222
}}
2323
>
2424
{props.children}

packages/active-element/dev/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@ export const genNodeList = () =>
33
x: Math.random() * (window.innerWidth - 192),
44
y: Math.random() * (window.innerHeight - 192),
55
size: Math.random() + 0.15,
6-
id
6+
id,
77
}));

packages/active-element/src/index.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ const getActiveElement = () =>
2727
* clear();
2828
*/
2929
export function makeActiveElementListener(
30-
callback: (element: Element | null) => void
30+
callback: (element: Element | null) => void,
3131
): VoidFunction {
3232
if (process.env.SSR) {
3333
return () => void 0;
@@ -71,7 +71,7 @@ export function createActiveElement(): Accessor<Element | null> {
7171
export function makeFocusListener(
7272
target: Element,
7373
callback: (isActive: boolean) => void,
74-
useCapture = true
74+
useCapture = true,
7575
): VoidFunction {
7676
if (process.env.SSR) {
7777
return () => void 0;
@@ -96,7 +96,7 @@ export function createFocusSignal(target: MaybeAccessor<Element>): Accessor<bool
9696
}
9797
const [isActive, setIsActive] = createHydrateSignal(
9898
false,
99-
() => document.activeElement === target
99+
() => document.activeElement === target,
100100
);
101101
createEventListener(target, "blur", () => setIsActive(false), true);
102102
createEventListener(target, "focus", () => setIsActive(true), true);

packages/active-element/test/index.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import {
66
createActiveElement,
77
makeFocusListener,
88
createFocusSignal,
9-
focus
9+
focus,
1010
} from "../src";
1111

1212
const dispatchFocusEvent = (target: Element | Window = window, event: "focus" | "blur" = "focus") =>

packages/analytics/src/ga.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ export const trackGoogleAnalytics: TrackHandler = (event, data) => {
3232
hitType: "social",
3333
socialNetwork: data.network,
3434
socialAction: data.action,
35-
socialTarget: data.target
35+
socialTarget: data.target,
3636
});
3737
break;
3838
case EventType.Event:
@@ -41,7 +41,7 @@ export const trackGoogleAnalytics: TrackHandler = (event, data) => {
4141
eventAction: data.action,
4242
eventLabel: data.label,
4343
eventValue: data.value,
44-
...data.other
44+
...data.other,
4545
});
4646
break;
4747
}

packages/analytics/src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
export enum EventType {
22
Pageview = "page",
33
Event = "event",
4-
Social = "social"
4+
Social = "social",
55
}
66
export type TrackEventData = {
77
category?: string;
@@ -22,7 +22,7 @@ export type TrackPageview = {
2222
};
2323
export type TrackHandler = (
2424
type: EventType,
25-
data: TrackEventData | TrackSocialData | TrackPageview
25+
data: TrackEventData | TrackSocialData | TrackPageview,
2626
) => void;
2727

2828
/**

packages/analytics/test/index.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ describe("createPrimitiveTemplate", () => {
88
const handlers = [...new Array(5)].map(
99
(_, i) =>
1010
(...args) =>
11-
(called[i] = args)
11+
(called[i] = args),
1212
);
1313
const track = createAnalytics(handlers);
1414
const eventData = {};

packages/audio/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ const { play, pause, seek } = makeAudioPlayer("example.mp3");
5050
```ts
5151
function makeAudioPlayer(
5252
src: AudioSource,
53-
handlers: AudioEventHandlers = {}
53+
handlers: AudioEventHandlers = {},
5454
): {
5555
play: VoidFunction;
5656
pause: VoidFunction;
@@ -82,7 +82,7 @@ _Note:_ Initializing the primitive with `playing` as true works, however note th
8282
function makeAudioPlayer(
8383
src: AudioSource | Accessor<AudioSource>,
8484
playing?: Accessor<boolean>,
85-
volume?: Accessor<number>
85+
volume?: Accessor<number>,
8686
): [
8787
{
8888
state: AudioState;
@@ -96,7 +96,7 @@ function makeAudioPlayer(
9696
setVolume: (volume: number) => void;
9797
play: VoidFunction;
9898
pause: VoidFunction;
99-
}
99+
},
100100
];
101101
```
102102

packages/audio/dev/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ const App: Component = () => {
5959
each={Object.entries({
6060
"Sample 1": "sample1.mp3",
6161
"Sample 2": "sample2.mp3",
62-
"Sample 3": "sample3.mp3"
62+
"Sample 3": "sample3.mp3",
6363
})}
6464
>
6565
{([label, url]) => (
@@ -70,7 +70,7 @@ const App: Component = () => {
7070
class="transition cursor-pointer bg-transparent px-4 py-3 border-none"
7171
classList={{
7272
"text-white hover:text-gray-900": url != source(),
73-
"text-blue-800": url == source()
73+
"text-blue-800": url == source(),
7474
}}
7575
>
7676
{label}

0 commit comments

Comments
 (0)