Skip to content

Commit

Permalink
meow
Browse files Browse the repository at this point in the history
  • Loading branch information
yofukashino committed Dec 16, 2023
1 parent 2e4555d commit 901134f
Show file tree
Hide file tree
Showing 13 changed files with 63 additions and 185 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Fluent presence icons, designed by Microsoft.

For other fluent icons, install [this theme by Stickfab](https://github.com/zuzumi-f/pc-fluenticons).

Direct Download Link: [dev.tharki.FluentStatusIcons.asar](https://github.com/Tharki-God/FluentStatusIcons/releases/latest/download/dev.tharki.FluentStatusIcons.asar)
Direct Download Link: [dev.tharki.FluentStatusIcons.asar](https://github.com/TharkiDev/FluentStatusIcons/releases/latest/download/dev.tharki.FluentStatusIcons.asar)

Install Link:

Expand Down
6 changes: 3 additions & 3 deletions manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
"name": "FluentStatusIcons",
"description": "Fluent presence icons, designed by Microsoft.",
"image": "https://i.imgur.com/8I17Thq.png",
"source": "https://github.com/Tharki-God/FluentStatusIcons",
"source": "https://github.com/TharkiDev/FluentStatusIcons",
"author": {
"name": "Ahlawat",
"discordID": "1025214794766221384",
"github": "Tharki-God"
"discordID": "1121961711080050780",
"github": "TharkiDev"
},
"version": "1.0.2",
"updater": {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"eslint-plugin-node": "^11.1.0",
"eslint-plugin-react": "^7.33.2",
"prettier": "^2.8.8",
"replugged": "^4.7.4",
"replugged": "^4.7.7",
"typescript": "^4.9.5"
}
}
30 changes: 13 additions & 17 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

89 changes: 21 additions & 68 deletions src/Components/FluentMasks.tsx
Original file line number Diff line number Diff line change
@@ -1,98 +1,51 @@
export const Online = (
<mask
{...{
id: "svg-mask-status-online",
maskContentUnits: "objectBoundingBox",
viewBox: "0 0 1 1",
}}>
<mask id="svg-mask-status-online" maskContentUnits="objectBoundingBox" viewBox="0 0 1 1">
<path
{...{
fill: "white",
d: "M 0.5 0 C 0.224 0 0 0.224 0 0.5 C 0 0.776 0.224 1 0.5 1 C 0.776 1 1 0.776 1 0.5 C 1 0.224 0.776 0 0.5 0 M 0.125 0.5 C 0.125 0.293 0.293 0.125 0.5 0.125 C 0.707 0.125 0.875 0.293 0.875 0.5 C 0.875 0.707 0.707 0.875 0.5 0.875 C 0.293 0.875 0.125 0.707 0.125 0.5",
}}
/>
<circle
{...{
fill: "white",
cx: "0.5",
cy: "0.5",
r: "0.2",
}}
fill="white"
d="M 0.5 0 C 0.224 0 0 0.224 0 0.5 C 0 0.776 0.224 1 0.5 1 C 0.776 1 1 0.776 1 0.5 C 1 0.224 0.776 0 0.5 0 M 0.125 0.5 C 0.125 0.293 0.293 0.125 0.5 0.125 C 0.707 0.125 0.875 0.293 0.875 0.5 C 0.875 0.707 0.707 0.875 0.5 0.875 C 0.293 0.875 0.125 0.707 0.125 0.5"
/>
<circle fill="white" cx="0.5" cy="0.5" r="0.2" />
</mask>
);
export const Phone = (
<mask
{...{
id: "svg-mask-status-online-mobile",
maskContentUnits: "objectBoundingBox",
viewBox: "0 0 1 1",
}}>
<mask id="svg-mask-status-online-mobile" maskContentUnits="objectBoundingBox" viewBox="0 0 1 1">
<path
{...{
fill: "white",
d: "M 0.813 0 C 0.918 0 1 0.051 1 0.113 L 1 0.887 C 1 0.949 0.918 1 0.813 1 L 0.188 1 C 0.082 1 0 0.949 0 0.887 L 0 0.113 C 0 0.051 0.082 0 0.188 0 Z M 0.813 0.074 L 0.188 0.074 C 0.152 0.074 0.125 0.09 0.125 0.113 L 0.125 0.887 C 0.125 0.91 0.152 0.926 0.188 0.926 L 0.813 0.926 C 0.848 0.926 0.875 0.91 0.875 0.887 L 0.875 0.113 C 0.875 0.09 0.848 0.074 0.813 0.074 Z M 0.605 0.773 C 0.637 0.773 0.668 0.793 0.668 0.813 C 0.668 0.832 0.641 0.852 0.605 0.852 L 0.395 0.852 C 0.363 0.852 0.332 0.832 0.332 0.813 C 0.332 0.793 0.359 0.773 0.395 0.773 Z",
}}
fill="white"
d="M 0.813 0 C 0.918 0 1 0.051 1 0.113 L 1 0.887 C 1 0.949 0.918 1 0.813 1 L 0.188 1 C 0.082 1 0 0.949 0 0.887 L 0 0.113 C 0 0.051 0.082 0 0.188 0 Z M 0.813 0.074 L 0.188 0.074 C 0.152 0.074 0.125 0.09 0.125 0.113 L 0.125 0.887 C 0.125 0.91 0.152 0.926 0.188 0.926 L 0.813 0.926 C 0.848 0.926 0.875 0.91 0.875 0.887 L 0.875 0.113 C 0.875 0.09 0.848 0.074 0.813 0.074 Z M 0.605 0.773 C 0.637 0.773 0.668 0.793 0.668 0.813 C 0.668 0.832 0.641 0.852 0.605 0.852 L 0.395 0.852 C 0.363 0.852 0.332 0.832 0.332 0.813 C 0.332 0.793 0.359 0.773 0.395 0.773 Z"
/>
</mask>
);
export const Idle = (
<mask
{...{
id: "svg-mask-status-idle",
maskContentUnits: "objectBoundingBox",
viewBox: "0 0 1 1",
}}>
<mask id="svg-mask-status-idle" maskContentUnits="objectBoundingBox" viewBox="0 0 1 1">
<path
{...{
fill: "white",
d: "M 0.604 0.01 C 0.67 0.02 0.709 0.043 0.764 0.082 C 0.859 0.145 0.933 0.229 0.971 0.349 C 1.031 0.551 0.938 0.765 0.832 0.863 C 0.778 0.905 0.718 0.946 0.647 0.968 C 0.301 1.061 0.051 0.842 0.01 0.541 C 0.088 0.56 0.158 0.588 0.234 0.577 C 0.446 0.553 0.613 0.361 0.618 0.179 C 0.629 0.118 0.611 0.057 0.604 0.01 Z M 0.725 0.181 C 0.723 0.253 0.686 0.412 0.577 0.52 C 0.509 0.591 0.446 0.623 0.367 0.649 C 0.237 0.679 0.206 0.674 0.154 0.676 C 0.184 0.739 0.236 0.786 0.295 0.821 C 0.329 0.843 0.367 0.86 0.406 0.871 C 0.639 0.943 0.81 0.764 0.867 0.617 C 0.954 0.354 0.751 0.197 0.725 0.181 Z",
}}
fill="white"
d="M 0.604 0.01 C 0.67 0.02 0.709 0.043 0.764 0.082 C 0.859 0.145 0.933 0.229 0.971 0.349 C 1.031 0.551 0.938 0.765 0.832 0.863 C 0.778 0.905 0.718 0.946 0.647 0.968 C 0.301 1.061 0.051 0.842 0.01 0.541 C 0.088 0.56 0.158 0.588 0.234 0.577 C 0.446 0.553 0.613 0.361 0.618 0.179 C 0.629 0.118 0.611 0.057 0.604 0.01 Z M 0.725 0.181 C 0.723 0.253 0.686 0.412 0.577 0.52 C 0.509 0.591 0.446 0.623 0.367 0.649 C 0.237 0.679 0.206 0.674 0.154 0.676 C 0.184 0.739 0.236 0.786 0.295 0.821 C 0.329 0.843 0.367 0.86 0.406 0.871 C 0.639 0.943 0.81 0.764 0.867 0.617 C 0.954 0.354 0.751 0.197 0.725 0.181 Z"
/>
</mask>
);
export const DND = (
<mask
{...{
id: "svg-mask-status-dnd",
maskContentUnits: "objectBoundingBox",
viewBox: "0 0 1 1",
}}>
<mask id="svg-mask-status-dnd" maskContentUnits="objectBoundingBox" viewBox="0 0 1 1">
<path
{...{
fill: "white",
d: "M 0.5 0 C 0.223 0 0 0.223 0 0.5 C 0 0.777 0.223 1 0.5 1 C 0.777 1 1 0.777 1 0.5 C 1 0.223 0.777 0 0.5 0 Z M 0.125 0.5 C 0.125 0.293 0.293 0.125 0.5 0.125 C 0.707 0.125 0.875 0.293 0.875 0.5 C 0.875 0.707 0.707 0.875 0.5 0.875 C 0.293 0.875 0.125 0.707 0.125 0.5 Z M 0.25 0.5 C 0.25 0.465 0.277 0.438 0.313 0.438 L 0.688 0.438 C 0.723 0.438 0.75 0.465 0.75 0.5 C 0.75 0.535 0.723 0.563 0.688 0.563 L 0.313 0.563 C 0.277 0.563 0.25 0.535 0.25 0.5 Z",
}}
fill="white"
d="M 0.5 0 C 0.223 0 0 0.223 0 0.5 C 0 0.777 0.223 1 0.5 1 C 0.777 1 1 0.777 1 0.5 C 1 0.223 0.777 0 0.5 0 Z M 0.125 0.5 C 0.125 0.293 0.293 0.125 0.5 0.125 C 0.707 0.125 0.875 0.293 0.875 0.5 C 0.875 0.707 0.707 0.875 0.5 0.875 C 0.293 0.875 0.125 0.707 0.125 0.5 Z M 0.25 0.5 C 0.25 0.465 0.277 0.438 0.313 0.438 L 0.688 0.438 C 0.723 0.438 0.75 0.465 0.75 0.5 C 0.75 0.535 0.723 0.563 0.688 0.563 L 0.313 0.563 C 0.277 0.563 0.25 0.535 0.25 0.5 Z"
/>
</mask>
);
export const Offline = (
<mask
{...{
id: "svg-mask-status-offline",
maskContentUnits: "objectBoundingBox",
viewBox: "0 0 1 1",
}}>
<mask id="svg-mask-status-offline" maskContentUnits="objectBoundingBox" viewBox="0 0 1 1">
<path
{...{
fill: "white",
d: "M 0.5 0 C 0.224 0 0 0.224 0 0.5 C 0 0.776 0.224 1 0.5 1 C 0.776 1 1 0.776 1 0.5 C 1 0.224 0.776 0 0.5 0 M 0.125 0.5 C 0.125 0.293 0.293 0.125 0.5 0.125 C 0.707 0.125 0.875 0.293 0.875 0.5 C 0.875 0.707 0.707 0.875 0.5 0.875 C 0.293 0.875 0.125 0.707 0.125 0.5",
}}
fill="white"
d="M 0.5 0 C 0.224 0 0 0.224 0 0.5 C 0 0.776 0.224 1 0.5 1 C 0.776 1 1 0.776 1 0.5 C 1 0.224 0.776 0 0.5 0 M 0.125 0.5 C 0.125 0.293 0.293 0.125 0.5 0.125 C 0.707 0.125 0.875 0.293 0.875 0.5 C 0.875 0.707 0.707 0.875 0.5 0.875 C 0.293 0.875 0.125 0.707 0.125 0.5"
/>
</mask>
);
export const Stream = (
<mask
{...{
id: "svg-mask-status-streaming",
maskContentUnits: "objectBoundingBox",
viewBox: "0 0 1 1",
}}>
<mask id="svg-mask-status-streaming" maskContentUnits="objectBoundingBox" viewBox="0 0 1 1">
<path
{...{
fill: "white",
d: "M 0.5 0.125 C 0.293 0.125 0.125 0.293 0.125 0.5 C 0.125 0.707 0.293 0.875 0.5 0.875 C 0.707 0.875 0.875 0.707 0.875 0.5 C 0.875 0.293 0.707 0.125 0.5 0.125 Z M 0 0.5 C 0 0.223 0.223 0 0.5 0 C 0.777 0 1 0.223 1 0.5 C 1 0.777 0.777 1 0.5 1 C 0.223 1 0 0.777 0 0.5 Z M 0 0.5 M 0.746 0.469 L 0.434 0.281 C 0.398 0.262 0.352 0.289 0.352 0.332 L 0.352 0.668 C 0.352 0.711 0.398 0.738 0.434 0.719 L 0.746 0.531 C 0.77 0.52 0.77 0.48 0.746 0.469 Z",
}}
fill="white"
d="M 0.5 0.125 C 0.293 0.125 0.125 0.293 0.125 0.5 C 0.125 0.707 0.293 0.875 0.5 0.875 C 0.707 0.875 0.875 0.707 0.875 0.5 C 0.875 0.293 0.707 0.125 0.5 0.125 Z M 0 0.5 C 0 0.223 0.223 0 0.5 0 C 0.777 0 1 0.223 1 0.5 C 1 0.777 0.777 1 0.5 1 C 0.223 1 0 0.777 0 0.5 Z M 0 0.5 M 0.746 0.469 L 0.434 0.281 C 0.398 0.262 0.352 0.289 0.352 0.332 L 0.352 0.668 C 0.352 0.711 0.398 0.738 0.434 0.719 L 0.746 0.531 C 0.77 0.52 0.77 0.48 0.746 0.469 Z"
/>
</mask>
);

export default { Online, Phone, Idle, DND, Offline, Stream };
38 changes: 13 additions & 25 deletions src/Components/Settings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { util } from "replugged";
import { SwitchItem } from "replugged/components";
import { PluginLogger, SettingValues } from "../index";
import { defaultSettings } from "../lib/consts";
import * as Types from "../types";
import Types from "../types";
export const registerSettings = (): void => {
for (const key in defaultSettings) {
if (SettingValues.has(key as keyof Types.Settings)) return;
Expand All @@ -15,45 +15,33 @@ export const Settings = () => {
return (
<div>
<SwitchItem
{...{
note: "Fluent Phone Icon",
...util.useSetting(SettingValues, "PhoneIcon", defaultSettings.PhoneIcon),
}}>
note="Fluent Phone Icon"
{...util.useSetting(SettingValues, "PhoneIcon", defaultSettings.PhoneIcon)}>
Phone Icon
</SwitchItem>
<SwitchItem
{...{
note: "Fluent Online Icon",
...util.useSetting(SettingValues, "OnlineIcon", defaultSettings.OnlineIcon),
}}>
note="Fluent Online Icon"
{...util.useSetting(SettingValues, "OnlineIcon", defaultSettings.OnlineIcon)}>
Online Icon
</SwitchItem>
<SwitchItem
{...{
note: "Fluent Idle Icon",
...util.useSetting(SettingValues, "IdleIcon", defaultSettings.IdleIcon),
}}>
note="Fluent Idle Icon"
{...util.useSetting(SettingValues, "IdleIcon", defaultSettings.IdleIcon)}>
Idle Icon
</SwitchItem>
<SwitchItem
{...{
note: "Fluent Do Not Disturb Icon",
...util.useSetting(SettingValues, "DNDIcon", defaultSettings.DNDIcon),
}}>
note="Fluent Do Not Disturb Icon"
{...util.useSetting(SettingValues, "DNDIcon", defaultSettings.DNDIcon)}>
DND Icon
</SwitchItem>
<SwitchItem
{...{
note: "Fluent Offline Icon",
...util.useSetting(SettingValues, "OfflineIcon", defaultSettings.OfflineIcon),
}}>
note="Fluent Offline Icon"
{...util.useSetting(SettingValues, "OfflineIcon", defaultSettings.OfflineIcon)}>
Offline Icon
</SwitchItem>
<SwitchItem
{...{
note: "Fluent Streaming Icon",
...util.useSetting(SettingValues, "StreamingIcon", defaultSettings.StreamingIcon),
}}>
note="Fluent Streaming Icon"
{...util.useSetting(SettingValues, "StreamingIcon", defaultSettings.StreamingIcon)}>
Streaming Icon
</SwitchItem>
</div>
Expand Down
4 changes: 2 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { registerSettings } from "./Components/Settings";

import { applyInjections } from "./patches/index";

import * as Utils from "./lib/utils";
import Utils from "./lib/utils";

export const start = (): void => {
registerSettings();
Expand All @@ -24,5 +24,5 @@ export const stop = (): void => {
PluginInjector.uninjectAll();
Utils.refreshMaskLibrary();
};
export { patchDirectMessageStatus } from "./patches/index";

export { Settings } from "./Components/Settings";
2 changes: 1 addition & 1 deletion src/lib/requiredModules.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { webpack } from "replugged";
import * as Types from "../types";
import Types from "../types";

export const Avatar = webpack.getBySource<Types.Avatar>("getMaskId()");
export const MaskManager = webpack.getByProps<Types.MaskLibrary>("MaskLibrary");
2 changes: 2 additions & 0 deletions src/lib/utils.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,5 @@ export const refreshMaskLibrary = (): void => {
PluginLogger.error(error);
}
};

export default { refreshMaskLibrary };
Loading

0 comments on commit 901134f

Please sign in to comment.