From 1d09bf45c6ace82c0e6e246c388859b8f19fb708 Mon Sep 17 00:00:00 2001 From: Jessica Mulein Date: Sun, 8 Sep 2024 20:38:47 +0000 Subject: [PATCH] Revamp fontawesome to use kit and improve capabilities. Update tests. --- Dockerfile | 4 +- apps/duality-social-node/src/middlewares.ts | 13 +- apps/duality-social-react/src/app/app.tsx | 13 +- .../src/components/format-guide.tsx | 165 ++++++++++++++++++ .../src/components/humanity-type-icon.tsx | 2 +- .../src/components/image-crop-dialog.tsx | 2 +- .../src/components/image-preview.tsx | 2 +- .../src/components/live-post-preview.tsx | 32 ++++ .../src/components/new-post.tsx | 9 +- .../src/components/top-menu.tsx | 2 +- .../src/components/user-profile-page.tsx | 2 +- apps/duality-social-react/src/index.html | 1 + apps/duality-social-react/src/main.tsx | 7 + .../src/utils/reactions.ts | 3 +- fontawesome-npmrc.sh | 3 +- .../src/lib/duality-social-lib.spec.ts | 2 +- .../src/lib/font-awesome/font-awesome.spec.ts | 100 +++++------ .../src/lib/font-awesome/font-awesome.ts | 77 ++++---- package.json | 15 +- tsconfig.base.json | 2 +- yarn.lock | 91 +--------- 21 files changed, 329 insertions(+), 218 deletions(-) create mode 100644 apps/duality-social-react/src/components/format-guide.tsx create mode 100644 apps/duality-social-react/src/components/live-post-preview.tsx diff --git a/Dockerfile b/Dockerfile index e6ad470..fb5fa58 100644 --- a/Dockerfile +++ b/Dockerfile @@ -17,9 +17,7 @@ COPY ./apps/duality-social-react ./apps/duality-social-react COPY ./apps/duality-social-node ./apps/duality-social-node # Build the application -RUN yarn fontawesome:setup -RUN yarn all -RUN yarn all:build +RUN yarn build:all:dev # Expose the desired port (e.g., 3000, 4200, or 8080) EXPOSE 3000 diff --git a/apps/duality-social-node/src/middlewares.ts b/apps/duality-social-node/src/middlewares.ts index f2baff2..cbb999d 100644 --- a/apps/duality-social-node/src/middlewares.ts +++ b/apps/duality-social-node/src/middlewares.ts @@ -28,12 +28,15 @@ export class Middlewares { // Helmet helps you secure your Express apps by setting various HTTP headers app.use(helmet({ contentSecurityPolicy: { - directives: { - ...helmet.contentSecurityPolicy.getDefaultDirectives(), - "img-src": ["'self'", "data:", "blob:"] - } + directives: { + ...helmet.contentSecurityPolicy.getDefaultDirectives(), + "img-src": ["'self'", "data:", "blob:"], + "script-src": ["'self'", "https://kit.fontawesome.com"], + "connect-src": ["'self'", "https://ka-p.fontawesome.com"], + "style-src": ["'self'", "https://ka-p.fontawesome.com", "'unsafe-inline'"] + } } - })); + })); // Enable CORS app.use(cors(Middlewares.corsOptionsDelegate)); // Parse incoming requests with JSON payloads diff --git a/apps/duality-social-react/src/app/app.tsx b/apps/duality-social-react/src/app/app.tsx index 174f9c6..b57d748 100644 --- a/apps/duality-social-react/src/app/app.tsx +++ b/apps/duality-social-react/src/app/app.tsx @@ -1,5 +1,7 @@ import React from 'react'; import { Route, Routes } from 'react-router-dom'; +import { ThemeProvider } from '@mui/material/styles'; +import { Box } from '@mui/material'; import DashboardPage from '../components/dashboard-page'; import { MenuProvider } from '../menu-context'; import TopMenu from '../components/top-menu'; @@ -10,10 +12,9 @@ import PrivateRoute from '../components/private-route'; import VerifyEmailPage from '../components/verify-email-page'; import ChangePasswordPage from '../components/change-password-page'; import ForgotPasswordPage from '../components/forgot-password-page'; -import { ThemeProvider } from '@mui/material/styles'; -import { Box } from '@mui/material'; import theme from '../theme'; import UserProfilePage from '../components/user-profile-page'; +import FormatGuide from '../components/format-guide'; function App() { return ( @@ -56,6 +57,14 @@ function App() { } /> + + + + } + /> diff --git a/apps/duality-social-react/src/components/format-guide.tsx b/apps/duality-social-react/src/components/format-guide.tsx new file mode 100644 index 0000000..a20d6d6 --- /dev/null +++ b/apps/duality-social-react/src/components/format-guide.tsx @@ -0,0 +1,165 @@ +import React from 'react'; +import { + Typography, + Paper, + List, + ListItem, + ListItemText, + Divider, + ListItemIcon, +} from '@mui/material'; +import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; +import { faHeart } from '@awesome.me/kit-89ec609b07/icons/classic/solid'; +import { faHeart as faHeartRegular } from '@awesome.me/kit-89ec609b07/icons/classic/regular'; + +const FormatGuide: React.FC = () => { + return ( + + + Post Formatting Guide + + +

+ You can use Markdown syntax and a special custom FontAwesome powered + icon markup in your posts. +

+

+ A complete list of icons available (we're using a complete Pro set) + can be found here{' '} + + https://fontawesome.com/icons + +

+

Here's a quick guide:

+
+ + + Markdown Syntax: + + + + + + + + + + + + + + + + + + Icon Markup: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Note: HTML tags are stripped for security reasons. Use Markdown and icon + markup for formatting. + + + For more detailed styling options, refer to the{' '} + + FontAwesome Style Cheatsheet + . Our markup is a custom shorthand for this. + +
+ ); +}; + +export default FormatGuide; \ No newline at end of file diff --git a/apps/duality-social-react/src/components/humanity-type-icon.tsx b/apps/duality-social-react/src/components/humanity-type-icon.tsx index 026cf6f..33d33b2 100644 --- a/apps/duality-social-react/src/components/humanity-type-icon.tsx +++ b/apps/duality-social-react/src/components/humanity-type-icon.tsx @@ -1,6 +1,6 @@ import React from 'react'; import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; -import { faUser, faRobot, faDesktop } from '@fortawesome/free-solid-svg-icons'; +import { faUser, faRobot, faDesktop } from '@awesome.me/kit-89ec609b07/icons/classic/regular'; import { HumanityTypeEnum } from '@duality-social/duality-social-lib'; interface HumanityTypeIconProps { diff --git a/apps/duality-social-react/src/components/image-crop-dialog.tsx b/apps/duality-social-react/src/components/image-crop-dialog.tsx index 6443e8d..d2994b1 100644 --- a/apps/duality-social-react/src/components/image-crop-dialog.tsx +++ b/apps/duality-social-react/src/components/image-crop-dialog.tsx @@ -1,7 +1,7 @@ import React, { useState, useCallback } from 'react'; import { Dialog, DialogActions, DialogContent, Button } from '@mui/material'; import Cropper from 'react-easy-crop'; -import { Point, Area } from 'react-easy-crop/types'; +import { Point, Area } from 'react-easy-crop'; interface ImageCropDialogProps { open: boolean; diff --git a/apps/duality-social-react/src/components/image-preview.tsx b/apps/duality-social-react/src/components/image-preview.tsx index e48c530..0b442d0 100644 --- a/apps/duality-social-react/src/components/image-preview.tsx +++ b/apps/duality-social-react/src/components/image-preview.tsx @@ -1,7 +1,7 @@ import React from 'react'; import { Box, IconButton } from '@mui/material'; import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; -import { faTrash, faPencilAlt } from '@fortawesome/free-solid-svg-icons'; +import { faTrash, faPencilAlt } from '@awesome.me/kit-89ec609b07/icons/classic/regular'; interface ImagePreviewProps { image: File; diff --git a/apps/duality-social-react/src/components/live-post-preview.tsx b/apps/duality-social-react/src/components/live-post-preview.tsx new file mode 100644 index 0000000..d35c49f --- /dev/null +++ b/apps/duality-social-react/src/components/live-post-preview.tsx @@ -0,0 +1,32 @@ +import React, { useState, useEffect } from 'react'; +import { Box, Typography } from '@mui/material'; +import { parsePostContent } from '@duality-social/duality-social-lib'; + +interface LivePostPreviewProps { + content: string; +} + +const LivePostPreview: React.FC = ({ content }) => { + const [parsedContent, setParsedContent] = useState(''); + + useEffect(() => { + setParsedContent(parsePostContent(content)); + }, [content]); + + return ( + + Preview: + + + ); +}; + +export default LivePostPreview; \ No newline at end of file diff --git a/apps/duality-social-react/src/components/new-post.tsx b/apps/duality-social-react/src/components/new-post.tsx index e04ba7a..16c8686 100644 --- a/apps/duality-social-react/src/components/new-post.tsx +++ b/apps/duality-social-react/src/components/new-post.tsx @@ -1,8 +1,10 @@ import React, { useState } from 'react'; -import { Button, TextField, Box } from '@mui/material'; +import { Link } from 'react-router-dom'; +import { Button, TextField, Box, Typography } from '@mui/material'; import { useFormik } from 'formik'; import * as Yup from 'yup'; import ImagePreview from './image-preview'; +import LivePostPreview from './live-post-preview'; import ImageCropDialog from './image-crop-dialog'; import authenticatedApi from '../services/authenticated-api'; import { AppConstants } from '@duality-social/duality-social-lib'; @@ -127,6 +129,10 @@ const NewPost: React.FC = ({ (parentPostId ? 'Write a reply' : "What's on your mind?") } /> + + Need help with formatting? Check out our{' '} + post formatting guide. + {images.map((img, index) => ( = ({ onClose={() => setCropDialogOpen(false)} onSave={handleCropSave} /> + ); }; diff --git a/apps/duality-social-react/src/components/top-menu.tsx b/apps/duality-social-react/src/components/top-menu.tsx index a19fd28..a99e5e7 100644 --- a/apps/duality-social-react/src/components/top-menu.tsx +++ b/apps/duality-social-react/src/components/top-menu.tsx @@ -11,7 +11,7 @@ import { Box, } from '@mui/material'; import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; -import { faUser, faComment } from '@fortawesome/free-solid-svg-icons'; +import { faUser, faComment } from '@awesome.me/kit-89ec609b07/icons/classic/regular'; import { AuthContext } from '../auth-provider'; import { CommentMenuOption, useMenu } from '../menu-context'; import dualitySocialSymbol from '../assets/DSImageOnlySmall.png'; diff --git a/apps/duality-social-react/src/components/user-profile-page.tsx b/apps/duality-social-react/src/components/user-profile-page.tsx index 1ad4c71..7600336 100644 --- a/apps/duality-social-react/src/components/user-profile-page.tsx +++ b/apps/duality-social-react/src/components/user-profile-page.tsx @@ -1,7 +1,7 @@ // file: user-profile.tsx import React, { useState, useEffect } from 'react'; import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; -import { faCheckCircle } from '@fortawesome/free-solid-svg-icons'; +import { faCheckCircle } from '@awesome.me/kit-89ec609b07/icons/classic/regular'; import { Box, Chip, diff --git a/apps/duality-social-react/src/index.html b/apps/duality-social-react/src/index.html index 092e9ce..c13e1fd 100644 --- a/apps/duality-social-react/src/index.html +++ b/apps/duality-social-react/src/index.html @@ -7,6 +7,7 @@ +
diff --git a/apps/duality-social-react/src/main.tsx b/apps/duality-social-react/src/main.tsx index 27d7e4d..4301326 100644 --- a/apps/duality-social-react/src/main.tsx +++ b/apps/duality-social-react/src/main.tsx @@ -1,10 +1,17 @@ import { StrictMode } from 'react'; import * as ReactDOM from 'react-dom/client'; import { BrowserRouter } from 'react-router-dom'; +import { config, library } from '@fortawesome/fontawesome-svg-core'; +import { all } from '@awesome.me/kit-89ec609b07/icons'; +import '@fortawesome/fontawesome-svg-core/styles.css'; import App from './app/app'; import { AuthProvider } from './auth-provider'; +// fontawesome +library.add(...all); +config.autoAddCss = false; + const root = ReactDOM.createRoot( document.getElementById('root') as HTMLElement ); diff --git a/apps/duality-social-react/src/utils/reactions.ts b/apps/duality-social-react/src/utils/reactions.ts index f513471..edfb7ba 100644 --- a/apps/duality-social-react/src/utils/reactions.ts +++ b/apps/duality-social-react/src/utils/reactions.ts @@ -1,5 +1,6 @@ import { DefaultReactionsTypeEnum } from '@duality-social/duality-social-lib'; -import { faFaceAngry, faFaceKissWinkHeart, faPartyHorn, faFaceSmilingHands, faFaceConfused, faFaceLaugh, faThumbsUp, faHeart, faFaceSadTear, faFaceHushed, faFaceDizzy, IconDefinition } from '@fortawesome/pro-solid-svg-icons'; +import { faFaceAngry, faFaceKissWinkHeart, faPartyHorn, faFaceSmilingHands, faFaceConfused, faFaceLaugh, faThumbsUp, faHeart, faFaceSadTear, faFaceHushed, faFaceDizzy } from '@awesome.me/kit-89ec609b07/icons/classic/regular'; +import { IconDefinition } from '@awesome.me/kit-89ec609b07/icons'; export const reactionEmojis: { [type in DefaultReactionsTypeEnum]: string } = { [DefaultReactionsTypeEnum.Angry]: '😡', diff --git a/fontawesome-npmrc.sh b/fontawesome-npmrc.sh index cf5f017..f876534 100755 --- a/fontawesome-npmrc.sh +++ b/fontawesome-npmrc.sh @@ -1,4 +1,5 @@ #!/bin/bash echo "@fortawesome:registry=https://npm.fontawesome.com/ -//npm.fontawesome.com/:_authToken=$FONTAWESOME_KEY" > .npmrc +@awesome.me:registry=https://npm.fontawesome.com/ +//npm.fontawesome.com/:_authToken=$FONTAWESOME_KEY" > .npmrc \ No newline at end of file diff --git a/libs/duality-social-lib/src/lib/duality-social-lib.spec.ts b/libs/duality-social-lib/src/lib/duality-social-lib.spec.ts index 8ef2656..2ef821c 100644 --- a/libs/duality-social-lib/src/lib/duality-social-lib.spec.ts +++ b/libs/duality-social-lib/src/lib/duality-social-lib.spec.ts @@ -3,7 +3,7 @@ import { parsePostContent } from './duality-social-lib'; describe('DualitySocialLib', () => { it('should do markdown and our cool icons', () => { const testMarkdown = '# Hello World\nThis is a test of our markdown parser.\n' + - 'This should be a red heart with a zig-zag through it -> {{duotone heart-pulse color: red;}}'; + 'This should be a red heart with a zig-zag through it -> {{duotone heart-pulse; color: red;}}'; const expectedHtml = '

Hello World

\n

This is a test of our markdown parser.
\n' + 'This should be a red heart with a zig-zag through it ->

\n'; diff --git a/libs/duality-social-lib/src/lib/font-awesome/font-awesome.spec.ts b/libs/duality-social-lib/src/lib/font-awesome/font-awesome.spec.ts index a93bad7..ee098bb 100644 --- a/libs/duality-social-lib/src/lib/font-awesome/font-awesome.spec.ts +++ b/libs/duality-social-lib/src/lib/font-awesome/font-awesome.spec.ts @@ -1,57 +1,47 @@ import { parseIconMarkup } from './font-awesome'; -describe('FontAwesome', () => { - it('should test {{thumbs-up}}', () => { - const input = 'xx{{thumbs-up}}yy'; - const output = parseIconMarkup(input); - expect(output).toBe('xxyy'); - }); - it('should test {{solid thumbs-up}}', () => { - const input = 'xx{{solid thumbs-up}}yy'; - const output = parseIconMarkup(input); - expect(output).toBe('xxyy'); - }); - it('should test {{sharpsolid thumbs-up}} and {{thumbs-up}}', () => { - const input = 'aa{{sharpsolid thumbs-up}}{{thumbs-up}}bb' - const output = parseIconMarkup(input); - expect(output).toBe('aa' + - 'bb'); - }); - it('should test {{solid thumbs-up}} and {{thumbs-up}}', () => { - const input = 'aa{{solid thumbs-up}}{{thumbs-up}}bb' - const output = parseIconMarkup(input); - expect(output).toBe('aa' + - 'bb'); - }); - it('should test {{solid thumbs-up foreground: white; background: black;}} and {{thumbs-up:}}', () => { - const input = 'aa{{solid thumbs-up foreground: white; background: black;}}{{thumbs-up}}bb' - const output = parseIconMarkup(input); - expect(output).toBe('aa' + - 'bb'); - }); - it('should pass a string without any tags through', () => { - const input = 'This is a trick test {{}}'; - const output = parseIconMarkup(input); - expect(output).toBe(input); - }); - it('Doesn\'t match a string with just a colon', () => { - const input = 'This is a trick test {{:}}'; - const output = parseIconMarkup(input); - expect(output).toBe(input); - }); - it('Doesn\'t match a string with just braces and a colon', () => { - const input = 'This is a trick test {blah : x}'; - const output = parseIconMarkup(input); - expect(output).toBe(input); - }); - it('Doesn\'t match a string with just braces and a colon', () => { - const input = 'This is a trick test {blah }}'; - const output = parseIconMarkup(input); - expect(output).toBe(input); - }); - it('Doesn\'t allow odd injections', () => { - const input = 'This is a trick test {{solid heart x x }}'; - const output = parseIconMarkup(input); - expect(output).toBe("This is a trick test {{solid heart x x }}"); - }); -}); +describe('parseIconMarkup', () => { + it('should handle single word icons', () => { + expect(parseIconMarkup('{{heart}}')).toBe(''); + }); + + it('should handle all valid styles', () => { + const styles = ['classic', 'duotone', 'light', 'regular', 'solid', 'thin', 'brands']; + styles.forEach(style => { + expect(parseIconMarkup(`{{${style} heart}}`)).toBe(``); + }); + expect(parseIconMarkup('{{sharpsolid heart}}')).toBe(''); + }); + + it('should handle all size classes', () => { + const sizes = ['xs', 'sm', 'lg', 'xl', '2xl', '1x', '2x', '3x', '4x', '5x', '6x', '7x', '8x', '9x', '10x']; + sizes.forEach(size => { + expect(parseIconMarkup(`{{heart ${size}}}`)).toBe(``); + }); + }); + + it('should handle all animation classes', () => { + const animations = ['spin', 'pulse', 'beat', 'fade', 'flip']; + animations.forEach(animation => { + expect(parseIconMarkup(`{{heart ${animation}}}`)).toBe(``); + }); + }); + + it('should handle multiple classes', () => { + expect(parseIconMarkup('{{solid heart lg spin}}')).toBe(''); + }); + + it('should handle custom styles', () => { + expect(parseIconMarkup('{{solid heart; color: red; font-size: 20px;}}')).toBe(''); + }); + + it('should handle multiple icons in a string', () => { + const input = 'Hello {{heart}} World {{solid star 2x spin}}'; + const expected = 'Hello World '; + expect(parseIconMarkup(input)).toBe(expected); + }); + + it('should handle combined usage with multiple classes and icon name', () => { + expect(parseIconMarkup('{{solid lg spin heart}}')).toBe(''); + }); +}); \ No newline at end of file diff --git a/libs/duality-social-lib/src/lib/font-awesome/font-awesome.ts b/libs/duality-social-lib/src/lib/font-awesome/font-awesome.ts index c43fad2..fb726d9 100644 --- a/libs/duality-social-lib/src/lib/font-awesome/font-awesome.ts +++ b/libs/duality-social-lib/src/lib/font-awesome/font-awesome.ts @@ -15,58 +15,41 @@ export const DefaultColorClass = FontAwesomeTextStyleTypeEnum.Regular; * @param input The string to be parsed * @returns parsed markup */ -export function parseIconMarkup(input: string): string { - const regex = /\{\{([a-zA-Z0-9-_;:%#&*! ^ ]+)\}\}/g; +export function parseIconMarkup(text: string): string { + const regex = /{{([^}]+)}}/g; + return text.replace(regex, (match, content) => { + const parts = content.split(';'); + const words = parts[0].trim().split(' '); + const styleParts = parts.slice(1); - let match: RegExpExecArray | null; - while ((match = regex.exec(input)) !== null) { - if (match[1] === undefined) { - continue; - } - const iconWords: string[] = []; - const styleWords: string[] = []; - const contents = match[1]; - if (!contents) { - continue; + const validStyles = ['classic', 'duotone', 'light', 'regular', 'solid', 'thin', 'brands', 'sharpsolid']; + const validAdditionalClasses = ['xs', 'sm', 'lg', 'xl', '2xl', '1x', '2x', '3x', '4x', '5x', '6x', '7x', '8x', '9x', '10x', 'spin', 'pulse', 'beat', 'fade', 'flip']; + + let iconClass = 'fa-regular'; + let additionalClasses = []; + let iconName = ''; + + if (validStyles.includes(words[0].toLowerCase())) { + iconClass = words[0].toLowerCase() === 'sharpsolid' ? 'fa-sharp fa-solid' : `fa-${words[0].toLowerCase()}`; + words.shift(); // Remove the style from words array } - let skip = false; - const words = contents.trim().split(' '); - for (let i = 0; i < words.length; i++) { - const word = words[i].trim(); - if (!word) { - skip = true; - continue; - } - if (!/[a-zA-Z0-9-_]+/.test(word)) { - skip = true; - continue; - } - if (i < 2 && word === 'sharpsolid') { - iconWords.push('fa-sharp'); - iconWords.push('fa-solid'); - } else if (i < 2) { - iconWords.push(`fa-${word.toLowerCase()}`); - } else { - styleWords.push(word); + + // Find the icon name (last word that's not a valid additional class) + for (let i = words.length - 1; i >= 0; i--) { + if (!validAdditionalClasses.includes(words[i].toLowerCase())) { + iconName = words[i]; + words.splice(i, 1); // Remove the icon name from words array + break; } } - if (skip) { - continue; - } - if (iconWords.length === 1) { - iconWords.unshift('fa-regular'); - } - let newTag = match[0]; - if (styleWords.length > 0) { - const styleAttr = ` style="display: inline-block; ${styleWords.join(' ')}"`; - newTag = ``; - } else { - newTag = ``; - } - input = input.replace(match[0], newTag); - } - return input; + additionalClasses = words.filter((cls: string) => validAdditionalClasses.includes(cls.toLowerCase())); + + const additionalClassesString = additionalClasses.length > 0 ? ` ${additionalClasses.map((cls: string) => `fa-${cls.toLowerCase()}`).join(' ')}` : ''; + const style = `display: inline-block;${styleParts.length > 0 ? styleParts.join(';') : ''}`.trim(); + + return ``; + }); } export function stripIconMarkup(input: string): string { diff --git a/package.json b/package.json index 7d051d1..7e8437f 100644 --- a/package.json +++ b/package.json @@ -16,6 +16,8 @@ "build:react": "npx nx build duality-social-react", "build:react:dev": "npx nx build duality-social-react --configuration development", "test:all": "npx nx test duality-social-lib && npx nx test duality-social-react && npx nx test duality-social-node", + "test:fontawesome": "npx nx test duality-social-lib --testFile=libs/duality-social-lib/src/lib/font-awesome/font-awesome.spec.ts", + "test:lib": "npx nx test duality-social-lib --testFile=libs/duality-social-lib/src/lib/duality-social-lib.spec.ts", "build": "yarn build:all", "build:serve": "NODE_ENV=production npx nx run-many --target=build --all --configuration=production && npx nx serve duality-social-node --configuration production", "build-serve:dev": "NODE_ENV=development npx nx run-many --target=build --all --configuration=development && npx nx serve duality-social-node --configuration development", @@ -33,23 +35,12 @@ "migrate:run-migrations": "npx nx migrate --run-migrations" }, "dependencies": { + "@awesome.me/kit-89ec609b07": "^1.0.4", "@emotion/react": "^11.13.3", "@emotion/styled": "^11.13.0", "@fortawesome/fontawesome-common-types": "^6.6.0", "@fortawesome/fontawesome-svg-core": "^6.6.0", - "@fortawesome/free-brands-svg-icons": "^6.6.0", - "@fortawesome/free-solid-svg-icons": "^6.6.0", - "@fortawesome/pro-duotone-svg-icons": "^6.6.0", - "@fortawesome/pro-light-svg-icons": "^6.6.0", - "@fortawesome/pro-regular-svg-icons": "^6.6.0", - "@fortawesome/pro-solid-svg-icons": "^6.6.0", - "@fortawesome/pro-thin-svg-icons": "^6.6.0", "@fortawesome/react-fontawesome": "^0.2.2", - "@fortawesome/sharp-duotone-solid-svg-icons": "^6.6.0", - "@fortawesome/sharp-light-svg-icons": "^6.6.0", - "@fortawesome/sharp-regular-svg-icons": "^6.6.0", - "@fortawesome/sharp-solid-svg-icons": "^6.6.0", - "@fortawesome/sharp-thin-svg-icons": "^6.6.0", "@mdx-js/react": "^3.0.1", "@mui/material": "^6.0.1", "@mui/styles": "^6.0.1", diff --git a/tsconfig.base.json b/tsconfig.base.json index 2d9c4da..9e9f56a 100644 --- a/tsconfig.base.json +++ b/tsconfig.base.json @@ -6,7 +6,7 @@ "sourceMap": true, "declaration": false, "esModuleInterop": true, - "moduleResolution": "node", + "moduleResolution": "nodenext", "emitDecoratorMetadata": true, "experimentalDecorators": true, "importHelpers": true, diff --git a/yarn.lock b/yarn.lock index b1db9d6..d319bbe 100644 --- a/yarn.lock +++ b/yarn.lock @@ -131,6 +131,13 @@ dependencies: tslib "^1.9.0" +"@awesome.me/kit-89ec609b07@^1.0.4": + version "1.0.4" + resolved "https://npm.fontawesome.com/@awesome.me/kit-89ec609b07/-/1.0.4/kit-89ec609b07-1.0.4.tgz#7eef0c3257df9ff024cfd2b1b3e6ddc5b11c620f" + integrity sha512-PfO3ewENzj/js5ePDvW+SfPbik7T0W6LjGMgha3x1+nw/VsRiDyHN9RR694qfnMVYDHYZ5sNEXsCzwDFYO8rKw== + dependencies: + "@fortawesome/fontawesome-common-types" "^6.6.0" + "@aws-crypto/crc32@5.2.0": version "5.2.0" resolved "https://registry.yarnpkg.com/@aws-crypto/crc32/-/crc32-5.2.0.tgz#cfcc22570949c98c6689cfcbd2d693d36cdae2e1" @@ -2120,55 +2127,6 @@ dependencies: "@fortawesome/fontawesome-common-types" "6.6.0" -"@fortawesome/free-brands-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/free-brands-svg-icons/-/6.6.0/free-brands-svg-icons-6.6.0.tgz#2797f2cc66d21e7e47fa64e680b8835e8d30e825" - integrity sha512-1MPD8lMNW/earme4OQi1IFHtmHUwAKgghXlNwWi9GO7QkTfD+IIaYpIai4m2YJEzqfEji3jFHX1DZI5pbY/biQ== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - -"@fortawesome/free-solid-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/free-solid-svg-icons/-/6.6.0/free-solid-svg-icons-6.6.0.tgz#061751ca43be4c4d814f0adbda8f006164ec9f3b" - integrity sha512-IYv/2skhEDFc2WGUcqvFJkeK39Q+HyPf5GHUrT/l2pKbtgEIv1al1TKd6qStR5OIwQdN1GZP54ci3y4mroJWjA== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - -"@fortawesome/pro-duotone-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/pro-duotone-svg-icons/-/6.6.0/pro-duotone-svg-icons-6.6.0.tgz#0f7dce04129337c088b2505b33583deefdc6ec87" - integrity sha512-ke5aL4+P0aTc5pxfP9JclD87LQX4sPdj9i2YpYeJaNArtHXc/3QheR98G1G9uk257jIXuI2HTfeCXW4N6+2TXQ== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - -"@fortawesome/pro-light-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/pro-light-svg-icons/-/6.6.0/pro-light-svg-icons-6.6.0.tgz#ac749aba5533a84fbfb9ce4d3067915ec34c367e" - integrity sha512-Seq2iIAcOO48VbOSBH1sS7Yr4PqXQ9ZQwua5YrJ5Gg+ESZagKrWIYT4iYg4HOFfZcZ7KdchedJ1go2MXuDahlA== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - -"@fortawesome/pro-regular-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/pro-regular-svg-icons/-/6.6.0/pro-regular-svg-icons-6.6.0.tgz#b16ca3be86eb73834263f8664d1a3b7f64627a68" - integrity sha512-T6ifZKYhLrEOWD2sOdqyJBblSSg5WqhtlmcVWhWViKTt2ZDqw9WstW/lG2jQK9hv5S5tqJwruab6XUPQEZqs5A== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - -"@fortawesome/pro-solid-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/pro-solid-svg-icons/-/6.6.0/pro-solid-svg-icons-6.6.0.tgz#e4f99d9b674288c3d1ccbec27b37e008bd190ca1" - integrity sha512-IwYuyO+i681arIxOjPUoqRwoHeTqeg6i2s5rY2WbZ1R7PnwavOd1+aPHCJlfU2k8l5LZ+u3hAKlVqu+emQFlZg== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - -"@fortawesome/pro-thin-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/pro-thin-svg-icons/-/6.6.0/pro-thin-svg-icons-6.6.0.tgz#1ac8e2fbc94b999e9aa608ab12d1db6434b25ec3" - integrity sha512-Kp378bhM7e9q0dzIt4hJ/Zgy+1AISQFHyXPT5QVZXQjyovYLy2g8pC+nNOyOwekPCjUNnHPBZVOIhi/Noa7ovg== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - "@fortawesome/react-fontawesome@^0.2.2": version "0.2.2" resolved "https://npm.fontawesome.com/@fortawesome/react-fontawesome/-/0.2.2/react-fontawesome-0.2.2.tgz#68b058f9132b46c8599875f6a636dad231af78d4" @@ -2176,41 +2134,6 @@ dependencies: prop-types "^15.8.1" -"@fortawesome/sharp-duotone-solid-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/sharp-duotone-solid-svg-icons/-/6.6.0/sharp-duotone-solid-svg-icons-6.6.0.tgz#b597d85ccb76d96201f4b56dfd42108e3c977433" - integrity sha512-x6iClIrV5tAYMgzqPMA9dgk9VFtyjnfwAnIJj2TBlhw+jlV9FTrwMm50Lf4p51HZf/yvd0paa1ojBYLnh/WqIw== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - -"@fortawesome/sharp-light-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/sharp-light-svg-icons/-/6.6.0/sharp-light-svg-icons-6.6.0.tgz#c0beddf3fcd5266f3b883f77255e80352fb8ed32" - integrity sha512-kdv/+ffolGEhhFCrVbaKCwFp0WHD+LagDzI9P6wtwaRS9c9opOgkOKVAhzu7jz1ry/4LSjZ67bstBbbsawTVmw== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - -"@fortawesome/sharp-regular-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/sharp-regular-svg-icons/-/6.6.0/sharp-regular-svg-icons-6.6.0.tgz#d2e08386f21204829309a8c9fe373205e0ad2660" - integrity sha512-rk69FW+8d+QYUD/YWQ7dNCUj1OffqhgshKZlVBtQRCku/yo6w7JNqkthpQMrJwwgAnBbqAJPtf9wREkCsC3I3A== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - -"@fortawesome/sharp-solid-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/sharp-solid-svg-icons/-/6.6.0/sharp-solid-svg-icons-6.6.0.tgz#fc3d89162ec49dd730d638cfcff2b219c2096c9a" - integrity sha512-LwVIF8/pr3kSCNunlvfMOOqA/nJhyVZF7yRljzJjeDeM+6m5FE1YpZa17HsiEZZ0FirSLn2iLF7In/niE5dWdA== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - -"@fortawesome/sharp-thin-svg-icons@^6.6.0": - version "6.6.0" - resolved "https://npm.fontawesome.com/@fortawesome/sharp-thin-svg-icons/-/6.6.0/sharp-thin-svg-icons-6.6.0.tgz#303dd7ca2093d178ab0146dbbe2eaca909f5624e" - integrity sha512-At9VXGxfgYXHfmm2mNevBr9wNJGkJV5K1fohxbOrqGzPlthVOcbTUDAcaoWdDIAsz716eTB9zD4MXHBK0Ru9CQ== - dependencies: - "@fortawesome/fontawesome-common-types" "6.6.0" - "@humanwhocodes/config-array@^0.11.14": version "0.11.14" resolved "https://registry.yarnpkg.com/@humanwhocodes/config-array/-/config-array-0.11.14.tgz#d78e481a039f7566ecc9660b4ea7fe6b1fec442b"