diff --git a/package.json b/package.json index f603252..5169660 100644 --- a/package.json +++ b/package.json @@ -9,6 +9,7 @@ "lint": "next lint" }, "dependencies": { + "@radix-ui/react-avatar": "^1.0.4", "@radix-ui/react-dropdown-menu": "^2.0.6", "@radix-ui/react-label": "^2.0.2", "@radix-ui/react-select": "^2.0.0", @@ -25,6 +26,7 @@ "node-html-parser": "^6.1.10", "react": "latest", "react-dom": "latest", + "sharp": "^0.32.6", "tailwind-merge": "^1.14.0", "tailwindcss-animate": "^1.0.7" }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 8a2b236..7f22e91 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -5,6 +5,9 @@ settings: excludeLinksFromLockfile: false dependencies: + '@radix-ui/react-avatar': + specifier: ^1.0.4 + version: 1.0.4(@types/react-dom@18.2.8)(@types/react@18.2.24)(react-dom@18.2.0)(react@18.2.0) '@radix-ui/react-dropdown-menu': specifier: ^2.0.6 version: 2.0.6(@types/react-dom@18.2.8)(@types/react@18.2.24)(react-dom@18.2.0)(react@18.2.0) @@ -53,6 +56,9 @@ dependencies: react-dom: specifier: latest version: 18.2.0(react@18.2.0) + sharp: + specifier: ^0.32.6 + version: 0.32.6 tailwind-merge: specifier: ^1.14.0 version: 1.14.0 @@ -364,6 +370,30 @@ packages: react-dom: 18.2.0(react@18.2.0) dev: false + /@radix-ui/react-avatar@1.0.4(@types/react-dom@18.2.8)(@types/react@18.2.24)(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-kVK2K7ZD3wwj3qhle0ElXhOjbezIgyl2hVvgwfIdexL3rN6zJmy5AqqIf+D31lxVppdzV8CjAfZ6PklkmInZLw==} + peerDependencies: + '@types/react': '*' + '@types/react-dom': '*' + react: ^16.8 || ^17.0 || ^18.0 + react-dom: ^16.8 || ^17.0 || ^18.0 + peerDependenciesMeta: + '@types/react': + optional: true + '@types/react-dom': + optional: true + dependencies: + '@babel/runtime': 7.23.1 + '@radix-ui/react-context': 1.0.1(@types/react@18.2.24)(react@18.2.0) + '@radix-ui/react-primitive': 1.0.3(@types/react-dom@18.2.8)(@types/react@18.2.24)(react-dom@18.2.0)(react@18.2.0) + '@radix-ui/react-use-callback-ref': 1.0.1(@types/react@18.2.24)(react@18.2.0) + '@radix-ui/react-use-layout-effect': 1.0.1(@types/react@18.2.24)(react@18.2.0) + '@types/react': 18.2.24 + '@types/react-dom': 18.2.8 + react: 18.2.0 + react-dom: 18.2.0(react@18.2.0) + dev: false + /@radix-ui/react-collection@1.0.3(@types/react-dom@18.2.8)(@types/react@18.2.24)(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-3SzW+0PW7yBBoQlT8wNcGtaxaD0XSu0uLUFgrtHY08Acx05TaHaOmVLR73c0j/cqpDy53KBMO7s0dx2wmOIDIA==} peerDependencies: @@ -1298,13 +1328,29 @@ packages: dequal: 2.0.3 dev: true + /b4a@1.6.4: + resolution: {integrity: sha512-fpWrvyVHEKyeEvbKZTVOeZF3VSKKWtJxFIxX/jaVPf+cLbGUSitjb49pHLqPV2BUNNZ0LcoeEGfE/YCpyDYHIw==} + dev: false + /balanced-match@1.0.2: resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} + /base64-js@1.5.1: + resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} + dev: false + /binary-extensions@2.2.0: resolution: {integrity: sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==} engines: {node: '>=8'} + /bl@4.1.0: + resolution: {integrity: sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==} + dependencies: + buffer: 5.7.1 + inherits: 2.0.4 + readable-stream: 3.6.2 + dev: false + /boolbase@1.0.0: resolution: {integrity: sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==} dev: false @@ -1332,6 +1378,13 @@ packages: update-browserslist-db: 1.0.13(browserslist@4.22.1) dev: true + /buffer@5.7.1: + resolution: {integrity: sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==} + dependencies: + base64-js: 1.5.1 + ieee754: 1.2.1 + dev: false + /busboy@1.6.0: resolution: {integrity: sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA==} engines: {node: '>=10.16.0'} @@ -1380,6 +1433,10 @@ packages: optionalDependencies: fsevents: 2.3.3 + /chownr@1.1.4: + resolution: {integrity: sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==} + dev: false + /class-variance-authority@0.7.0: resolution: {integrity: sha512-jFI8IQw4hczaL4ALINxqLEXQbWcNjoSkloa4IaufXCJr6QawJyw7tuRysRsrE8w2p/4gGaxKIt/hX3qz/IbD1A==} dependencies: @@ -1404,11 +1461,24 @@ packages: engines: {node: '>=7.0.0'} dependencies: color-name: 1.1.4 - dev: true /color-name@1.1.4: resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} - dev: true + + /color-string@1.9.1: + resolution: {integrity: sha512-shrVawQFojnZv6xM40anx4CkoDP+fZsw/ZerEMsW/pyzsRbElpsL/DBVW7q3ExxwusdNXI3lXpuhEZkzs8p5Eg==} + dependencies: + color-name: 1.1.4 + simple-swizzle: 0.2.2 + dev: false + + /color@4.2.3: + resolution: {integrity: sha512-1rXeuUUiGGrykh+CeBdu5Ie7OJwinCgQY0bc7GCRxy5xVHy+moaqkpL/jqQq0MtQOeYcrqEz4abc5f0KtU7W4A==} + engines: {node: '>=12.5.0'} + dependencies: + color-convert: 2.0.1 + color-string: 1.9.1 + dev: false /combined-stream@1.0.8: resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} @@ -1507,6 +1577,18 @@ packages: resolution: {integrity: sha512-VBBaLc1MgL5XpzgIP7ny5Z6Nx3UrRkIViUkPUdtl9aya5amy3De1gsUUSB1g3+3sExYNjCAsAznmukyxCb1GRA==} dev: false + /decompress-response@6.0.0: + resolution: {integrity: sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==} + engines: {node: '>=10'} + dependencies: + mimic-response: 3.1.0 + dev: false + + /deep-extend@0.6.0: + resolution: {integrity: sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==} + engines: {node: '>=4.0.0'} + dev: false + /deep-is@0.1.4: resolution: {integrity: sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==} dev: true @@ -1539,6 +1621,11 @@ packages: engines: {node: '>=6'} dev: true + /detect-libc@2.0.2: + resolution: {integrity: sha512-UX6sGumvvqSaXgdKGUsgZWqcUyIXZ/vZTrlRT/iobiKhGL0zL4d3osHj3uqllWJK+i+sixDS/3COVEOFbupFyw==} + engines: {node: '>=8'} + dev: false + /detect-node-es@1.1.0: resolution: {integrity: sha512-ypdmJU/TbBby2Dxibuv7ZLW3Bs1QEmM7nHjEANfohJLvE0XVujisn1qPJcZxg+qDucsr+bP6fLD1rPS3AhJ7EQ==} dev: false @@ -1612,6 +1699,12 @@ packages: resolution: {integrity: sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==} dev: true + /end-of-stream@1.4.4: + resolution: {integrity: sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==} + dependencies: + once: 1.4.0 + dev: false + /enhanced-resolve@5.15.0: resolution: {integrity: sha512-LXYT42KJ7lpIKECr2mAXIaMldcNCh/7E0KBKOu4KSfkHmP+mZmSs+8V5gBAqisWBy0OO4W5Oyys0GO1Y8KtdKg==} engines: {node: '>=10.13.0'} @@ -1996,10 +2089,19 @@ packages: engines: {node: '>=0.10.0'} dev: true + /expand-template@2.0.3: + resolution: {integrity: sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==} + engines: {node: '>=6'} + dev: false + /fast-deep-equal@3.1.3: resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} dev: true + /fast-fifo@1.3.2: + resolution: {integrity: sha512-/d9sfos4yxzpwkDkuN7k2SqFKtYNmCTzgfEpz82x34IM9/zc8KGxQoXg1liNC/izpRM/MBdt44Nmx41ZWqk+FQ==} + dev: false + /fast-glob@3.3.1: resolution: {integrity: sha512-kNFPyjhh5cKjrUltxs+wFx+ZkbRaxxmZ+X0ZU31SOsxCEtP9VPgtq2teZw1DebupL5GmDaNQ6yKMMVcM41iqDg==} engines: {node: '>=8.6.0'} @@ -2076,6 +2178,10 @@ packages: resolution: {integrity: sha512-n2aZ9tNfYDwaHhvFTkhFErqOMIb8uyzSQ+vGJBjZyanAKZVbGUQ1sngfk9FdkBw7G26O7AgNjLcecLffD1c7eg==} dev: true + /fs-constants@1.0.0: + resolution: {integrity: sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==} + dev: false + /fs.realpath@1.0.0: resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} @@ -2131,6 +2237,10 @@ packages: resolve-pkg-maps: 1.0.0 dev: true + /github-from-package@0.0.0: + resolution: {integrity: sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==} + dev: false + /glob-parent@5.1.2: resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==} engines: {node: '>= 6'} @@ -2296,6 +2406,10 @@ packages: safer-buffer: 2.1.2 dev: false + /ieee754@1.2.1: + resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==} + dev: false + /ignore@5.2.4: resolution: {integrity: sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ==} engines: {node: '>= 4'} @@ -2323,6 +2437,10 @@ packages: /inherits@2.0.4: resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} + /ini@1.3.8: + resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==} + dev: false + /internal-slot@1.0.5: resolution: {integrity: sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==} engines: {node: '>= 0.4'} @@ -2346,6 +2464,10 @@ packages: is-typed-array: 1.1.12 dev: true + /is-arrayish@0.3.2: + resolution: {integrity: sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==} + dev: false + /is-async-function@2.0.0: resolution: {integrity: sha512-Y1JXKrfykRJGdlDwdKlLpLyMIiWqWvuSd17TvZk68PLAOGOoF4Xyav1z0Xhoi+gCYjZVeC5SI+hYFOfvXmGRCA==} engines: {node: '>= 0.4'} @@ -2650,7 +2772,6 @@ packages: engines: {node: '>=10'} dependencies: yallist: 4.0.0 - dev: true /lucide-react@0.279.0(react@18.2.0): resolution: {integrity: sha512-LJ8g66+Bxc3t3x9vKTeK3wn3xucrOQGfJ9ou9GsBwCt2offsrT2BB90XrTrIzE1noYYDe2O8jZaRHi6sAHXNxw==} @@ -2683,6 +2804,11 @@ packages: mime-db: 1.52.0 dev: false + /mimic-response@3.1.0: + resolution: {integrity: sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==} + engines: {node: '>=10'} + dev: false + /minimatch@3.1.2: resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} dependencies: @@ -2690,7 +2816,10 @@ packages: /minimist@1.2.8: resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} - dev: true + + /mkdirp-classic@0.5.3: + resolution: {integrity: sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==} + dev: false /ms@2.1.2: resolution: {integrity: sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==} @@ -2711,6 +2840,10 @@ packages: engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} hasBin: true + /napi-build-utils@1.0.2: + resolution: {integrity: sha512-ONmRUqK7zj7DWX0D9ADe03wbwOBZxNAfF20PlGfCWQcD3+/MakShIHrMqx9YwPTfxDdF1zLeL+RGZiR9kGMLdg==} + dev: false + /natural-compare@1.4.0: resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} dev: true @@ -2767,6 +2900,17 @@ packages: - babel-plugin-macros dev: false + /node-abi@3.47.0: + resolution: {integrity: sha512-2s6B2CWZM//kPgwnuI0KrYwNjfdByE25zvAaEpq9IH4zcNsarH8Ihu/UuX6XMPEogDAxkuUFeZn60pXNHAqn3A==} + engines: {node: '>=10'} + dependencies: + semver: 7.5.4 + dev: false + + /node-addon-api@6.1.0: + resolution: {integrity: sha512-+eawOlIgy680F0kBzPUNFhMZGtJ1YmqM6l4+Crf4IkImjYrO/mqPwRMh352g23uIaQKFItcQ64I7KMaJxHgAVA==} + dev: false + /node-html-parser@6.1.10: resolution: {integrity: sha512-6/uWdWxjQWQ7tMcFK2wWlrflsQUzh1HsEzlIf2j5+TtzfhT2yUvg3DwZYAmjEHeR3uX74ko7exjHW69J0tOzIg==} dependencies: @@ -3019,6 +3163,25 @@ packages: picocolors: 1.0.0 source-map-js: 1.0.2 + /prebuild-install@7.1.1: + resolution: {integrity: sha512-jAXscXWMcCK8GgCoHOfIr0ODh5ai8mj63L2nWrjuAgXE6tDyYGnx4/8o/rCgU+B4JSyZBKbeZqzhtwtC3ovxjw==} + engines: {node: '>=10'} + hasBin: true + dependencies: + detect-libc: 2.0.2 + expand-template: 2.0.3 + github-from-package: 0.0.0 + minimist: 1.2.8 + mkdirp-classic: 0.5.3 + napi-build-utils: 1.0.2 + node-abi: 3.47.0 + pump: 3.0.0 + rc: 1.2.8 + simple-get: 4.0.1 + tar-fs: 2.1.1 + tunnel-agent: 0.6.0 + dev: false + /prelude-ls@1.2.1: resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} engines: {node: '>= 0.8.0'} @@ -3036,6 +3199,13 @@ packages: resolution: {integrity: sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag==} dev: false + /pump@3.0.0: + resolution: {integrity: sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==} + dependencies: + end-of-stream: 1.4.4 + once: 1.4.0 + dev: false + /punycode@2.3.0: resolution: {integrity: sha512-rRV+zQD8tVFys26lAGR9WUuS4iUAngJScM+ZRSKtvl5tKeZ2t5bvdNFdNHBW9FWR4guGHlgmsZ1G7BSm2wTbuA==} engines: {node: '>=6'} @@ -3047,6 +3217,20 @@ packages: /queue-microtask@1.2.3: resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==} + /queue-tick@1.0.1: + resolution: {integrity: sha512-kJt5qhMxoszgU/62PLP1CJytzd2NKetjSRnyuj31fDd3Rlcz3fzlFdFLD1SItunPwyqEOkca6GbV612BWfaBag==} + dev: false + + /rc@1.2.8: + resolution: {integrity: sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==} + hasBin: true + dependencies: + deep-extend: 0.6.0 + ini: 1.3.8 + minimist: 1.2.8 + strip-json-comments: 2.0.1 + dev: false + /react-dom@18.2.0(react@18.2.0): resolution: {integrity: sha512-6IMTriUmvsjHUjNtEDudZfuDQUoWXVxKHhlEGSk81n4YFS+r/Kl99wXiwlVXtPBtJenozv2P+hxDsw9eA7Xo6g==} peerDependencies: @@ -3125,6 +3309,15 @@ packages: dependencies: pify: 2.3.0 + /readable-stream@3.6.2: + resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==} + engines: {node: '>= 6'} + dependencies: + inherits: 2.0.4 + string_decoder: 1.3.0 + util-deprecate: 1.0.2 + dev: false + /readdirp@3.6.0: resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==} engines: {node: '>=8.10.0'} @@ -3215,6 +3408,10 @@ packages: isarray: 2.0.5 dev: true + /safe-buffer@5.2.1: + resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} + dev: false + /safe-regex-test@1.0.0: resolution: {integrity: sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==} dependencies: @@ -3251,7 +3448,6 @@ packages: hasBin: true dependencies: lru-cache: 6.0.0 - dev: true /set-function-name@2.0.1: resolution: {integrity: sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==} @@ -3262,6 +3458,21 @@ packages: has-property-descriptors: 1.0.0 dev: true + /sharp@0.32.6: + resolution: {integrity: sha512-KyLTWwgcR9Oe4d9HwCwNM2l7+J0dUQwn/yf7S0EnTtb0eVS4RxO0eUSvxPtzT4F3SY+C4K6fqdv/DO27sJ/v/w==} + engines: {node: '>=14.15.0'} + requiresBuild: true + dependencies: + color: 4.2.3 + detect-libc: 2.0.2 + node-addon-api: 6.1.0 + prebuild-install: 7.1.1 + semver: 7.5.4 + simple-get: 4.0.1 + tar-fs: 3.0.4 + tunnel-agent: 0.6.0 + dev: false + /shebang-command@2.0.0: resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} engines: {node: '>=8'} @@ -3282,6 +3493,24 @@ packages: object-inspect: 1.12.3 dev: true + /simple-concat@1.0.1: + resolution: {integrity: sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==} + dev: false + + /simple-get@4.0.1: + resolution: {integrity: sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==} + dependencies: + decompress-response: 6.0.0 + once: 1.4.0 + simple-concat: 1.0.1 + dev: false + + /simple-swizzle@0.2.2: + resolution: {integrity: sha512-JA//kQgZtbuY83m+xT+tXJkmJncGMTFT+C+g2h2R9uxkYIrE2yy9sgmcLhCnw57/WSD+Eh3J97FPEDFnbXnDUg==} + dependencies: + is-arrayish: 0.3.2 + dev: false + /slash@3.0.0: resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} engines: {node: '>=8'} @@ -3296,6 +3525,13 @@ packages: engines: {node: '>=10.0.0'} dev: false + /streamx@2.15.1: + resolution: {integrity: sha512-fQMzy2O/Q47rgwErk/eGeLu/roaFWV0jVsogDmrszM9uIw8L5OA+t+V93MgYlufNptfjmYR1tOMWhei/Eh7TQA==} + dependencies: + fast-fifo: 1.3.2 + queue-tick: 1.0.1 + dev: false + /string.prototype.matchall@4.0.10: resolution: {integrity: sha512-rGXbGmOEosIQi6Qva94HUjgPs9vKW+dkG7Y8Q5O2OYkWL6wFaTRZO8zM4mhP94uX55wgyrXzfS2aGtGzUL7EJQ==} dependencies: @@ -3335,6 +3571,12 @@ packages: es-abstract: 1.22.2 dev: true + /string_decoder@1.3.0: + resolution: {integrity: sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==} + dependencies: + safe-buffer: 5.2.1 + dev: false + /strip-ansi@6.0.1: resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} engines: {node: '>=8'} @@ -3347,6 +3589,11 @@ packages: engines: {node: '>=4'} dev: true + /strip-json-comments@2.0.1: + resolution: {integrity: sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==} + engines: {node: '>=0.10.0'} + dev: false + /strip-json-comments@3.1.1: resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} engines: {node: '>=8'} @@ -3444,6 +3691,42 @@ packages: engines: {node: '>=6'} dev: true + /tar-fs@2.1.1: + resolution: {integrity: sha512-V0r2Y9scmbDRLCNex/+hYzvp/zyYjvFbHPNgVTKfQvVrb6guiE/fxP+XblDNR011utopbkex2nM4dHNV6GDsng==} + dependencies: + chownr: 1.1.4 + mkdirp-classic: 0.5.3 + pump: 3.0.0 + tar-stream: 2.2.0 + dev: false + + /tar-fs@3.0.4: + resolution: {integrity: sha512-5AFQU8b9qLfZCX9zp2duONhPmZv0hGYiBPJsyUdqMjzq/mqVpy/rEUSeHk1+YitmxugaptgBh5oDGU3VsAJq4w==} + dependencies: + mkdirp-classic: 0.5.3 + pump: 3.0.0 + tar-stream: 3.1.6 + dev: false + + /tar-stream@2.2.0: + resolution: {integrity: sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==} + engines: {node: '>=6'} + dependencies: + bl: 4.1.0 + end-of-stream: 1.4.4 + fs-constants: 1.0.0 + inherits: 2.0.4 + readable-stream: 3.6.2 + dev: false + + /tar-stream@3.1.6: + resolution: {integrity: sha512-B/UyjYwPpMBv+PaFSWAmtYjwdrlEaZQEhMIBFNC5oEG8lpiW8XjcSdmEaClj28ArfKScKHs2nshz3k2le6crsg==} + dependencies: + b4a: 1.6.4 + fast-fifo: 1.3.2 + streamx: 2.15.1 + dev: false + /text-table@0.2.0: resolution: {integrity: sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==} dev: true @@ -3507,6 +3790,12 @@ packages: resolution: {integrity: sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==} dev: false + /tunnel-agent@0.6.0: + resolution: {integrity: sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==} + dependencies: + safe-buffer: 5.2.1 + dev: false + /type-check@0.4.0: resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} engines: {node: '>= 0.8.0'} @@ -3758,7 +4047,6 @@ packages: /yallist@4.0.0: resolution: {integrity: sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==} - dev: true /yaml@2.3.2: resolution: {integrity: sha512-N/lyzTPaJasoDmfV7YTrYCI0G/3ivm/9wdG0aHuheKowWQwGTsK0Eoiw6utmzAnI6pkJa0DUVygvp3spqqEKXg==} diff --git a/public/teachers/2014-aitasova-a-z.jpg b/public/teachers/2014-aitasova-a-z.jpg new file mode 100644 index 0000000..68c7f2d Binary files /dev/null and b/public/teachers/2014-aitasova-a-z.jpg differ diff --git a/public/teachers/2014-karpeeva-a-s.jpg b/public/teachers/2014-karpeeva-a-s.jpg new file mode 100644 index 0000000..2b89a08 Binary files /dev/null and b/public/teachers/2014-karpeeva-a-s.jpg differ diff --git a/public/teachers/2014-kuntaeva.jpg b/public/teachers/2014-kuntaeva.jpg new file mode 100644 index 0000000..23c4f40 Binary files /dev/null and b/public/teachers/2014-kuntaeva.jpg differ diff --git a/public/teachers/2014-shomas.jpg b/public/teachers/2014-shomas.jpg new file mode 100644 index 0000000..6a288d3 Binary files /dev/null and b/public/teachers/2014-shomas.jpg differ diff --git a/public/teachers/2019-mihalkova.jpg b/public/teachers/2019-mihalkova.jpg new file mode 100644 index 0000000..d6d6276 Binary files /dev/null and b/public/teachers/2019-mihalkova.jpg differ diff --git a/public/teachers/2019-utibaeva-s-m.jpg b/public/teachers/2019-utibaeva-s-m.jpg new file mode 100644 index 0000000..c0677f5 Binary files /dev/null and b/public/teachers/2019-utibaeva-s-m.jpg differ diff --git a/public/teachers/9GLhbTgC.jpg b/public/teachers/9GLhbTgC.jpg new file mode 100644 index 0000000..9e7fed5 Binary files /dev/null and b/public/teachers/9GLhbTgC.jpg differ diff --git a/public/teachers/9GLhbTgCmhk.jpg b/public/teachers/9GLhbTgCmhk.jpg new file mode 100644 index 0000000..f32541d Binary files /dev/null and b/public/teachers/9GLhbTgCmhk.jpg differ diff --git a/public/teachers/DSC06789.JPG b/public/teachers/DSC06789.JPG new file mode 100644 index 0000000..d3661ef Binary files /dev/null and b/public/teachers/DSC06789.JPG differ diff --git a/public/teachers/IMG-f8eeb02.jpg b/public/teachers/IMG-f8eeb02.jpg new file mode 100644 index 0000000..ba87792 Binary files /dev/null and b/public/teachers/IMG-f8eeb02.jpg differ diff --git a/public/teachers/IMG_5419.jpg b/public/teachers/IMG_5419.jpg new file mode 100644 index 0000000..e6b0e0f Binary files /dev/null and b/public/teachers/IMG_5419.jpg differ diff --git a/public/teachers/abalimova-l-.jpg b/public/teachers/abalimova-l-.jpg new file mode 100644 index 0000000..941d5e1 Binary files /dev/null and b/public/teachers/abalimova-l-.jpg differ diff --git a/public/teachers/alehin-i-n.jpg b/public/teachers/alehin-i-n.jpg new file mode 100644 index 0000000..72b4550 Binary files /dev/null and b/public/teachers/alehin-i-n.jpg differ diff --git a/public/teachers/andriushenko.jpg b/public/teachers/andriushenko.jpg new file mode 100644 index 0000000..0d58ed1 Binary files /dev/null and b/public/teachers/andriushenko.jpg differ diff --git a/public/teachers/antonov-a-s.jpg b/public/teachers/antonov-a-s.jpg new file mode 100644 index 0000000..ff1aff7 Binary files /dev/null and b/public/teachers/antonov-a-s.jpg differ diff --git a/public/teachers/asdasad.jpg b/public/teachers/asdasad.jpg new file mode 100644 index 0000000..8c9a9c3 Binary files /dev/null and b/public/teachers/asdasad.jpg differ diff --git a/public/teachers/chernenkova-n-v.jpg b/public/teachers/chernenkova-n-v.jpg new file mode 100644 index 0000000..02223a8 Binary files /dev/null and b/public/teachers/chernenkova-n-v.jpg differ diff --git a/public/teachers/dmitrieva-n-v.jpg b/public/teachers/dmitrieva-n-v.jpg new file mode 100644 index 0000000..ccba716 Binary files /dev/null and b/public/teachers/dmitrieva-n-v.jpg differ diff --git a/public/teachers/ermolaeva-g-v.jpg b/public/teachers/ermolaeva-g-v.jpg new file mode 100644 index 0000000..42316b7 Binary files /dev/null and b/public/teachers/ermolaeva-g-v.jpg differ diff --git a/public/teachers/fedotova-e-.jpg b/public/teachers/fedotova-e-.jpg new file mode 100644 index 0000000..df186b8 Binary files /dev/null and b/public/teachers/fedotova-e-.jpg differ diff --git a/public/teachers/fomin-a-v.jpg b/public/teachers/fomin-a-v.jpg new file mode 100644 index 0000000..6585ee6 Binary files /dev/null and b/public/teachers/fomin-a-v.jpg differ diff --git a/public/teachers/fsdadsd.jpg b/public/teachers/fsdadsd.jpg new file mode 100644 index 0000000..72f1872 Binary files /dev/null and b/public/teachers/fsdadsd.jpg differ diff --git a/public/teachers/gorwenina-o-n.jpg b/public/teachers/gorwenina-o-n.jpg new file mode 100644 index 0000000..3f09ad5 Binary files /dev/null and b/public/teachers/gorwenina-o-n.jpg differ diff --git a/public/teachers/hodotova.jpg b/public/teachers/hodotova.jpg new file mode 100644 index 0000000..5ffa4e1 Binary files /dev/null and b/public/teachers/hodotova.jpg differ diff --git a/public/teachers/jilina.jpg b/public/teachers/jilina.jpg new file mode 100644 index 0000000..699887f Binary files /dev/null and b/public/teachers/jilina.jpg differ diff --git a/public/teachers/karpova-i-v.jpg b/public/teachers/karpova-i-v.jpg new file mode 100644 index 0000000..68da2e9 Binary files /dev/null and b/public/teachers/karpova-i-v.jpg differ diff --git a/public/teachers/konovalova.jpg b/public/teachers/konovalova.jpg new file mode 100644 index 0000000..4d48156 Binary files /dev/null and b/public/teachers/konovalova.jpg differ diff --git a/public/teachers/kornilova-s-a.jpg b/public/teachers/kornilova-s-a.jpg new file mode 100644 index 0000000..24da821 Binary files /dev/null and b/public/teachers/kornilova-s-a.jpg differ diff --git a/public/teachers/kozko-d-i.jpg b/public/teachers/kozko-d-i.jpg new file mode 100644 index 0000000..a4402ee Binary files /dev/null and b/public/teachers/kozko-d-i.jpg differ diff --git a/public/teachers/kukarskaya-l-p.jpg b/public/teachers/kukarskaya-l-p.jpg new file mode 100644 index 0000000..e920226 Binary files /dev/null and b/public/teachers/kukarskaya-l-p.jpg differ diff --git a/public/teachers/lizunova.jpg b/public/teachers/lizunova.jpg new file mode 100644 index 0000000..f659cbc Binary files /dev/null and b/public/teachers/lizunova.jpg differ diff --git a/public/teachers/lobacheva-m-e.jpg b/public/teachers/lobacheva-m-e.jpg new file mode 100644 index 0000000..460ce4b Binary files /dev/null and b/public/teachers/lobacheva-m-e.jpg differ diff --git a/public/teachers/logvinov_a_v.jpg b/public/teachers/logvinov_a_v.jpg new file mode 100644 index 0000000..dfe1af2 Binary files /dev/null and b/public/teachers/logvinov_a_v.jpg differ diff --git a/public/teachers/matulina.jpg b/public/teachers/matulina.jpg new file mode 100644 index 0000000..d7b24c4 Binary files /dev/null and b/public/teachers/matulina.jpg differ diff --git a/public/teachers/nazarova.jpg b/public/teachers/nazarova.jpg new file mode 100644 index 0000000..c8f8434 Binary files /dev/null and b/public/teachers/nazarova.jpg differ diff --git a/public/teachers/nekrylova-t-b.jpg b/public/teachers/nekrylova-t-b.jpg new file mode 100644 index 0000000..2c6fef3 Binary files /dev/null and b/public/teachers/nekrylova-t-b.jpg differ diff --git a/public/teachers/nikiforov-m-m.jpg b/public/teachers/nikiforov-m-m.jpg new file mode 100644 index 0000000..d2b832a Binary files /dev/null and b/public/teachers/nikiforov-m-m.jpg differ diff --git a/public/teachers/pershina-e-v.jpg b/public/teachers/pershina-e-v.jpg new file mode 100644 index 0000000..e341ee9 Binary files /dev/null and b/public/teachers/pershina-e-v.jpg differ diff --git a/public/teachers/qwefdsfsd.jpg b/public/teachers/qwefdsfsd.jpg new file mode 100644 index 0000000..846fb2b Binary files /dev/null and b/public/teachers/qwefdsfsd.jpg differ diff --git a/public/teachers/samoylova.jpg b/public/teachers/samoylova.jpg new file mode 100644 index 0000000..69757f4 Binary files /dev/null and b/public/teachers/samoylova.jpg differ diff --git a/public/teachers/shamber-l-n.jpg b/public/teachers/shamber-l-n.jpg new file mode 100644 index 0000000..ccf4f19 Binary files /dev/null and b/public/teachers/shamber-l-n.jpg differ diff --git a/public/teachers/shykova.jpg b/public/teachers/shykova.jpg new file mode 100644 index 0000000..70e3b73 Binary files /dev/null and b/public/teachers/shykova.jpg differ diff --git a/public/teachers/sinekopova-l-v.jpg b/public/teachers/sinekopova-l-v.jpg new file mode 100644 index 0000000..781904d Binary files /dev/null and b/public/teachers/sinekopova-l-v.jpg differ diff --git a/public/teachers/sirotkina-o-v.jpg b/public/teachers/sirotkina-o-v.jpg new file mode 100644 index 0000000..2a75583 Binary files /dev/null and b/public/teachers/sirotkina-o-v.jpg differ diff --git a/public/teachers/sitnikova-l-.jpg b/public/teachers/sitnikova-l-.jpg new file mode 100644 index 0000000..2108f1a Binary files /dev/null and b/public/teachers/sitnikova-l-.jpg differ diff --git a/public/teachers/slavkina-t-a.jpg b/public/teachers/slavkina-t-a.jpg new file mode 100644 index 0000000..04308ac Binary files /dev/null and b/public/teachers/slavkina-t-a.jpg differ diff --git a/public/teachers/sorokina-n.jpg b/public/teachers/sorokina-n.jpg new file mode 100644 index 0000000..822f37e Binary files /dev/null and b/public/teachers/sorokina-n.jpg differ diff --git a/public/teachers/stranik.jpg b/public/teachers/stranik.jpg new file mode 100644 index 0000000..1f3667b Binary files /dev/null and b/public/teachers/stranik.jpg differ diff --git a/public/teachers/terexin.jpg b/public/teachers/terexin.jpg new file mode 100644 index 0000000..a922d13 Binary files /dev/null and b/public/teachers/terexin.jpg differ diff --git a/public/teachers/tryaskina-s-s.jpg b/public/teachers/tryaskina-s-s.jpg new file mode 100644 index 0000000..4b446d6 Binary files /dev/null and b/public/teachers/tryaskina-s-s.jpg differ diff --git a/public/teachers/Чаденкова DSC06721.JPG b/public/teachers/Чаденкова DSC06721.JPG new file mode 100644 index 0000000..6c0e78b Binary files /dev/null and b/public/teachers/Чаденкова DSC06721.JPG differ diff --git a/public/teachers/авпкупып.jpg b/public/teachers/авпкупып.jpg new file mode 100644 index 0000000..2086490 Binary files /dev/null and b/public/teachers/авпкупып.jpg differ diff --git a/public/teachers/сиднина.jpg b/public/teachers/сиднина.jpg new file mode 100644 index 0000000..144cae9 Binary files /dev/null and b/public/teachers/сиднина.jpg differ diff --git a/src/shadcn/ui/avatar.tsx b/src/shadcn/ui/avatar.tsx new file mode 100644 index 0000000..a051a30 --- /dev/null +++ b/src/shadcn/ui/avatar.tsx @@ -0,0 +1,48 @@ +import * as React from "react" +import * as AvatarPrimitive from "@radix-ui/react-avatar" + +import { cn } from "@/shared/utils" + +const Avatar = React.forwardRef< + React.ElementRef, + React.ComponentPropsWithoutRef +>(({ className, ...props }, ref) => ( + +)) +Avatar.displayName = AvatarPrimitive.Root.displayName + +const AvatarImage = React.forwardRef< + React.ElementRef, + React.ComponentPropsWithoutRef +>(({ className, ...props }, ref) => ( + +)) +AvatarImage.displayName = AvatarPrimitive.Image.displayName + +const AvatarFallback = React.forwardRef< + React.ElementRef, + React.ComponentPropsWithoutRef +>(({ className, ...props }, ref) => ( + +)) +AvatarFallback.displayName = AvatarPrimitive.Fallback.displayName + +export { Avatar, AvatarImage, AvatarFallback } diff --git a/src/shared/data/teachers-photos/.gitignore b/src/shared/data/teachers-photos/.gitignore new file mode 100644 index 0000000..fa3432f --- /dev/null +++ b/src/shared/data/teachers-photos/.gitignore @@ -0,0 +1,2 @@ +sources/* +sources/urls.txt \ No newline at end of file diff --git a/src/shared/data/teachers-photos/scripts/crop.mjs b/src/shared/data/teachers-photos/scripts/crop.mjs new file mode 100644 index 0000000..b026dfa --- /dev/null +++ b/src/shared/data/teachers-photos/scripts/crop.mjs @@ -0,0 +1,47 @@ +import fs from 'fs/promises' +import path from 'path' +import sharp from 'sharp' + +import { dirname } from 'path' +import { fileURLToPath } from 'url' + +const __dirname = dirname(fileURLToPath(import.meta.url)) + '/' + +async function cropImages(imagePaths) { + try { + await fs.mkdir(__dirname + '../cropped') + } catch (err) { + if (err.code !== 'EEXIST') { + console.error('Failed to create directory:', err) + return + } + } + + for (const imagePath of imagePaths) { + const imageFileName = path.basename(imagePath) + const outputFileName = `${__dirname}../cropped/${imageFileName}` + + try { + const image = sharp(imagePath) + const metadata = await image.metadata() + + const minDimension = Math.min(metadata.width, metadata.height) + + await image + .extract({ left: 0, top: 0, width: minDimension, height: minDimension }) + .resize(96, 96, { fit: 'contain' }) + .toFile(outputFileName) + + console.log(`Successfully cropped ${imageFileName}`) + } catch (err) { + console.error(`Failed to crop ${imageFileName}:`, err) + } + } +} + +const files = await fs.readdir(__dirname + '../sources') +const imagePaths = files + .filter(f => f.toLowerCase().endsWith('.jpg') || f.toLowerCase().endsWith('.png')) + .map(f => __dirname + '../sources/' + f) + +await cropImages(imagePaths) \ No newline at end of file diff --git a/src/shared/data/teachers-photos/scripts/download.zsh b/src/shared/data/teachers-photos/scripts/download.zsh new file mode 100755 index 0000000..c001d13 --- /dev/null +++ b/src/shared/data/teachers-photos/scripts/download.zsh @@ -0,0 +1,28 @@ +#!/usr/bin/env zsh + +# Read each line from urls.txt +while IFS= read -r url; do + # Extract file name from URL + filename=$(basename $url) + + # Download the content to a temporary file + temp_file=$(mktemp) + curl -s -o $temp_file $url + + # Check if download was successful + if [[ $? -eq 0 ]]; then + # Use 'file --mime-type' to determine the mime type of the file + content_type=$(file --mime-type -b $temp_file) + + # Check if the content type starts with 'image' + if [[ $content_type == image/* ]]; then + echo "$filename downloaded successfully." + mv $temp_file $filename + else + echo "Skipping $filename (Content type is not image)." + rm -f $temp_file + fi + else + echo "Failed to download $filename." + fi +done < urls.txt diff --git a/src/shared/data/teachers-photos/scripts/rename-decode.mjs b/src/shared/data/teachers-photos/scripts/rename-decode.mjs new file mode 100644 index 0000000..ca6ef79 --- /dev/null +++ b/src/shared/data/teachers-photos/scripts/rename-decode.mjs @@ -0,0 +1,16 @@ +import fs from 'fs/promises' + +import { dirname } from 'path' +import { fileURLToPath } from 'url' + +const __dirname = dirname(fileURLToPath(import.meta.url)) + '/' + +const files = await fs.readdir(__dirname + '../sources') +const images = files + .filter(f => f.toLowerCase().endsWith('.jpg') || f.toLowerCase().endsWith('.png')) + .filter(f => f.startsWith('%')) + +for(const image of images) { + console.log(image, '->', decodeURIComponent(image)) + await fs.rename(__dirname + '../sources/' + image, __dirname + '../sources/' + decodeURIComponent(image)) +} \ No newline at end of file diff --git a/src/shared/data/teachers.ts b/src/shared/data/teachers.ts new file mode 100644 index 0000000..852821d --- /dev/null +++ b/src/shared/data/teachers.ts @@ -0,0 +1,247 @@ +// https://gist.github.com/VityaSchel/28f1a360ee7798511765910b39c6086c +export const teachers = [ + { + 'name': 'Абалымова Людмила Павловна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/abalimova-l-.jpg' + }, + { + 'name': 'Абрамова Светлана Геннадьевна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/qwefdsfsd.jpg' + }, + { + 'name': 'Алехин Иван Николаевич', + 'picture': 'https://ks.psuti.ru/images/stories/emp/alehin-i-n.jpg' + }, + { + 'name': 'Амукова Светлана Николаевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/' + }, + { + 'name': 'Андреева Елена Сергеевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/-i-n.jpg' + }, + { + 'name': 'Андреевская Наталья Владимировна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2021/IMG_5419.jpg' + }, + { + 'name': 'Андрющенко Анна Вячеславовна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/andriushenko.jpg' + }, + { + 'name': 'Арефьев Андрей Андреевич', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/%20class=' + }, + { + 'name': 'Бондаренко Анастасия Вячеславовна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/9GLhbTgCmhk.jpg' + }, + { + 'name': 'Горшенина Ольга Николаевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/gorwenina-o-n.jpg' + }, + { + 'name': 'Дмитриева Наталья Владимировна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/dmitrieva-n-v.jpg' + }, + { + 'name': 'Елисеева Эмиля Владиславовна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/9GLhbTgC.jpg' + }, + { + 'name': 'Ермолаева Галина Владимировна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/ermolaeva-g-v.jpg' + }, + { + 'name': 'Жабборова Светлана Сергеевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/tryaskina-s-s.jpg' + }, + { + 'name': 'Жилина Елена Николаевна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/jilina.jpg' + }, + { + 'name': 'Иванова Мария Сергеевна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/konovalova.jpg' + }, + { + 'name': 'Карпеева Александра Сергеевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/2014-karpeeva-a-s.jpg' + }, + { + 'name': 'Карпова Ирина Васильевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/karpova-i-v.jpg' + }, + { + 'name': 'Козько Диана Игоревна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/kozko-d-i.jpg' + }, + { + 'name': 'Корнилова Светлана Александровна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/kornilova-s-a.jpg' + }, + { + 'name': 'Краюшкина Ольга Борисовна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/fsdadsd.jpg' + }, + { + 'name': 'Крынкина Анна Андреевна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/%D0%A7%D0%B0%D0%B4%D0%B5%D0%BD%D0%BA%D0%BE%D0%B2%D0%B0%20DSC06721.JPG' + }, + { + 'name': 'Кукарская Людмила Петровна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/kukarskaya-l-p.jpg' + }, + { + 'name': 'Кусаева Зарина Владимировна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2022/%D0%B0%D0%B2%D0%BF%D0%BA%D1%83%D0%BF%D1%8B%D0%BF.jpg' + }, + { + 'name': 'Ларионова Софья Николаевна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/.jpg' + }, + { + 'name': 'Лизунова Елена Владимировна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/lizunova.jpg' + }, + { + 'name': 'Лобачева Милана Евгеньевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/lobacheva-m-e.jpg' + }, + { + 'name': 'Логвинов Александр Владимирович', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/logvinov_a_v.jpg' + }, + { + 'name': 'Малбасарова Галия Худанбаевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/2014-kuntaeva.jpg' + }, + { + 'name': 'Матулина Татьяна Сергеевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/matulina.jpg' + }, + { + 'name': 'Михалькова Ирина Евгеньевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/2019-mihalkova.jpg' + }, + { + 'name': 'Назарова Елена Федоровна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/nazarova.jpg' + }, + { + 'name': 'Негина Айгуль Зинуловна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/2014-aitasova-a-z.jpg' + }, + { + 'name': 'Некрылова Татьяна Борисовна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/nekrylova-t-b.jpg' + }, + { + 'name': 'Никифоров Михаил Михайлович', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/nikiforov-m-m.jpg' + }, + { + 'name': 'Першина Елена Викторовна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/pershina-e-v.jpg' + }, + { + 'name': 'Потяйкин Роман Владимирович', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/.jpg' + }, + { + 'name': 'Рзаева Алина Игоревна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/DSC06789.JPG' + }, + { + 'name': 'Савич Мария Владимировна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/asdasad.jpg' + }, + { + 'name': 'Самойлова Наталья Николаевна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2022/samoylova.jpg' + }, + { + 'name': 'Семенов Антон Сергеевич', + 'picture': 'https://ks.psuti.ru/images/stories/emp/antonov-a-s.jpg' + }, + { + 'name': 'Сергеев Роман Алексеевич', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/.jpg' + }, + { + 'name': 'Сиднина Юлия Валерьевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/%D1%81%D0%B8%D0%B4%D0%BD%D0%B8%D0%BD%D0%B0.jpg' + }, + { + 'name': 'Синекопова Лариса Владимировна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/sinekopova-l-v.jpg' + }, + { + 'name': 'Сироткина Ольга Владимировна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/sirotkina-o-v.jpg' + }, + { + 'name': 'Ситникова Людмила Геннадьевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/sitnikova-l-.jpg' + }, + { + 'name': 'Славкина Татьяна Анатольевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/slavkina-t-a.jpg' + }, + { + 'name': 'Сорокина Надежда Леонидовна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/sorokina-n.jpg' + }, + { + 'name': 'Странник Дмитрий Христианович', + 'picture': 'https://ks.psuti.ru/images/stories/emp/stranik.jpg' + }, + { + 'name': 'Тананыхина Надежда Воалимировна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/IMG-f8eeb02.jpg' + }, + { + 'name': 'Терёхин Дмитрий Вячеславович', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/terexin.jpg' + }, + { + 'name': 'Упанова Анастасия Владимировна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/.jpg' + }, + { + 'name': 'Утыбаева Светлана Михайловна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/2019-utibaeva-s-m.jpg' + }, + { + 'name': 'Федотова Елена Дмитриевна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/fedotova-e-.jpg' + }, + { + 'name': 'Фомин Александр Васильевич', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/fomin-a-v.jpg' + }, + { + 'name': 'Ходотова Евгения Андреевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/hodotova.jpg' + }, + { + 'name': 'Черненкова Наталья Владимировна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/chernenkova-n-v.jpg' + }, + { + 'name': 'Шамбер Лола Низамовна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/shamber-l-n.jpg' + }, + { + 'name': 'Шомас Елена Александровна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/2014-shomas.jpg' + }, + { + 'name': 'Шукова Марина Геннадьевна', + 'picture': 'https://ks.psuti.ru/images/stories/emp/new/shykova.jpg' + }, + { + 'name': 'Щербакова Надежда Юрьевна', + 'picture': 'https://ks.psuti.ru/images/stories/ks-news/2016/prepodavateli-foto/andreeva.jpg' + } +] \ No newline at end of file diff --git a/src/widgets/schedule/day.tsx b/src/widgets/schedule/day.tsx index f3dd3f2..c9b7539 100644 --- a/src/widgets/schedule/day.tsx +++ b/src/widgets/schedule/day.tsx @@ -1,9 +1,29 @@ import type { Day as DayType } from '@/shared/model/day' +import { Lesson } from '@/widgets/schedule/lesson' export function Day({ day }: { day: DayType }) { + const dayOfWeek = [ + 'Понедельник', + 'Вторник', + 'Среда', + 'Четверг', + 'Пятница', + 'Суббота', + 'Воскресенье' + ][day.date.getDay()-1] + return ( -

+
+

+ {dayOfWeek} +

+
+ {day.lessons.map((lesson, i) => ( + + ))} +
+
) } \ No newline at end of file diff --git a/src/widgets/schedule/index.tsx b/src/widgets/schedule/index.tsx index 1027fbf..61eac1f 100644 --- a/src/widgets/schedule/index.tsx +++ b/src/widgets/schedule/index.tsx @@ -6,7 +6,7 @@ export function Schedule({ days }: { }) { return ( -
+
{days.map((day, i) => ( ))} diff --git a/src/widgets/schedule/lesson.tsx b/src/widgets/schedule/lesson.tsx index 6084057..2de2fca 100644 --- a/src/widgets/schedule/lesson.tsx +++ b/src/widgets/schedule/lesson.tsx @@ -7,46 +7,49 @@ import { CardHeader, CardTitle, } from '@/shadcn/ui/card' -import { Input } from '@/shadcn/ui/input' -import { Label } from '@/shadcn/ui/label' import { - Select, - SelectContent, - SelectItem, - SelectTrigger, - SelectValue, -} from '@/shadcn/ui/select' + Avatar, + AvatarFallback, + AvatarImage, +} from '@/shadcn/ui/avatar' +import { teachers } from '@/shared/data/teachers' +import { Lesson as LessonType } from '@/shared/model/lesson' + +export function Lesson({ lesson }: { + lesson: LessonType +}) { + const teacherObj = lesson.teacher ? teachers.find(t => t.name === lesson.teacher) : null + + const getTeacherPhoto = (url?: string) => { + if(url) { + try { + const filename = decodeURIComponent(new URL(url).pathname.split('/').pop()!) + return `/teachers/${filename}` + } catch(e) { + console.error(e) + return null + } + } else { + return null + } + } -export function Lesson() { return ( - - - Create project - Deploy your new project in one-click. - + +
+ + + CN + + + + {lesson.subject} + {lesson.teacher} + {lesson.place?.classroom} + +
-
-
-
- - -
-
- - -
-
-
+