Skip to content

Commit

Permalink
Add emoji for these versions
Browse files Browse the repository at this point in the history
  • Loading branch information
Dianliang233 committed Oct 26, 2023
1 parent 625effe commit 981c920
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/components/form/JavaForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ export default function JavaForm({
.find((c) => c.name === m)
?.contains?.filter(predicate),
)
.filter(undefinedPredicate) as string[]
.filter(undefinedPredicate)
},
[
api.je_modules.collection,
Expand All @@ -165,7 +165,7 @@ export default function JavaForm({
.includes(resourceModules.name),
)
.flatMap((resourceModule) => resourceModule.incompatible_with)
.filter(undefinedPredicate) as string[]
.filter(undefinedPredicate)
},
[
api.je_modules.collection,
Expand Down Expand Up @@ -278,11 +278,13 @@ export default function JavaForm({
version: '23w43a+',
format: 20,
caption: t('form.version.captions.snapshot'),
emoji: emojis.bat,
},
{
version: '1.20.2',
format: 18,
caption: t('form.version.captions.release'),
emoji: emojis.moneyWithWings,
},
{
version: '1.20 - 1.20.1',
Expand Down
14 changes: 14 additions & 0 deletions src/components/form/emojis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,18 @@ interface Emoji {
svg: string
}

const bat: Emoji = {
shortcode: 'bat',
char: '🦇',
svg: '<svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 36 36"><path fill="#66757F" d="M23 21c0 6.352-3 10-5 10s-5-3.648-5-10s2.239-7 5-7c2.762 0 5 .648 5 7z"/><circle cx="18" cy="11" r="4" fill="#66757F"/><path fill="#66757F" d="M14 11c-2-5 1-7 1-7s2 1 2 4s-3 3-3 3z"/><path fill="#546066" d="M14.668 9.904c-.776-2.457-.119-3.896.403-4.58C15.486 5.773 16 6.608 16 8c0 1.268-.739 1.734-1.332 1.904z"/><path fill="#66757F" d="M22 11c2-5-1-7-1-7s-2 1-2 4s3 3 3 3zm-5.984 3c-1.62 1.157-10 2-9-5c.142-.99-1-1-2 0c-3 3-6 7.834-4 20c3-5 6-4 7 1c3-4 6-2 8 0c3-3 0-16 0-16zm3.937 0c1.62 1.157 10 2 9-5c-.142-.99 1-1 2 0c3 3 6 7.834 4 20c-3-5-6-4-7 1c-3-4-6-2-8 0c-3-3 0-16 0-16z"/><circle cx="16" cy="11" r="1" fill="#292F33"/><circle cx="20" cy="11" r="1" fill="#292F33"/><path fill="#546066" d="M21.332 9.904c.775-2.457.118-3.896-.403-4.58C20.514 5.773 20 6.608 20 8c0 1.268.739 1.734 1.332 1.904z"/><path fill="#99AAB5" d="M7.996 26.91c.892-2.691.573-5.988-.996-9.91c-1.487-3.719-1.315-6.329-1.129-7.423c-.049.041-.096.078-.148.13C3.017 12.414.477 16.531 1.66 26.436c1.276-1.379 2.412-1.723 3.228-1.723c1.265 0 2.333.783 3.108 2.197z"/><path fill="#99AAB5" d="M6.832 13.25c-.019-.03-.041-.058-.06-.087C7 16 8.4 17.001 9 20c.588 2.94.476 5.519.088 7.564c.839-.571 1.726-.874 2.656-.874c1.264 0 2.548.538 3.895 1.627C14 19 9 17 6.832 13.25zm21.172 13.66c-.893-2.691-.572-5.988.996-9.91c1.487-3.719 1.315-6.329 1.129-7.423c.049.041.097.078.148.13c2.706 2.707 5.246 6.824 4.063 16.729c-1.275-1.379-2.412-1.723-3.227-1.723c-1.266 0-2.334.783-3.109 2.197z"/><path fill="#99AAB5" d="m29.168 13.25l.061-.087C29 16 27.6 17.001 27 20c-.588 2.94-.477 5.519-.088 7.564c-.84-.571-1.726-.874-2.656-.874c-1.264 0-2.548.538-3.895 1.627C22 19 27 17 29.168 13.25zm-10.48-.144a.975.975 0 0 1-1.375 0l-.57-.571c-.378-.378-.25-.688.285-.688h1.945c.535 0 .664.309.285.688l-.57.571z"/></svg>',
}

const moneyWithWings: Emoji = {
shortcode: 'money_with_wings',
char: '💸',
svg: '<svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 36 36"><path fill="#5C913B" d="M35.602 16.28c-2.582-3.761-7.92 1.774-17.662 2.899c-3.607.416-6.857 3.428-11.047 3.141c-1.718-.118-4.117-5.061-5.913-4.273c-.924.406-1.348 1.761-.398 2.779L11.13 33.412s.536.618 2.342.19c.445.131 7.135-2.55 11.003-7.917c.926-1.285 2.03-2.355 3.173-3.249c3.711-2.744 7.745-3.7 7.745-3.7c.516-.426.637-.879.609-1.272c.034-.656-.4-1.184-.4-1.184z"/><path fill="#A7D28B" d="M11.476 10.274c-3.783 5.25-10.408 7.737-10.408 7.737c-1.236 1.047-.192 2.281-.192 2.281l10.438 12.359s.522.617 2.28.189c0 0 6.625-2.482 10.407-7.732c3.899-5.41 10.93-7.118 10.93-7.118c1.235-1.047.192-2.283.192-2.283L24.685 3.35s-.522-.618-2.28-.192c0 0-7.03 1.704-10.929 7.116z"/><circle cx="22" cy="14" r="5.5" fill="#77B255"/><path fill="#5C913B" d="M12.873 31.929c-.881 0-1.204-.328-1.248-.378L2.216 20.568c-.018-.021-.495-.567-.437-1.261c.035-.421.253-.796.647-1.115l.063-.038c.061-.024 6.163-2.532 9.583-7.065l.2.15l-.2-.15c3.618-4.796 9.859-6.854 9.921-6.874c1.745-.406 2.316.174 2.377.242l9.285 11.044c.017.018.493.566.435 1.261c-.035.42-.253.795-.647 1.114l-.099.049c-.061.015-6.129 1.523-9.644 6.181c-3.499 4.64-9.607 7.642-9.668 7.671c-.464.11-.846.152-1.159.152zm-.871-.707c.001 0 .452.416 1.865.088c.008-.011 6.009-2.962 9.436-7.504c3.437-4.555 9.225-6.182 9.867-6.351c.257-.221.399-.466.422-.729c.042-.48-.312-.893-.315-.897L23.992 4.784c-.002 0-.45-.415-1.864-.087c-.041.014-6.135 2.026-9.656 6.693c-3.366 4.461-9.239 6.995-9.758 7.213c-.268.225-.414.476-.437.745c-.04.476.312.887.315.891l9.41 10.983z"/><path fill="#FFAC33" d="m21.276 22.166l-.006 5.94l.497.59c.969-.884 1.9-1.878 2.705-2.996a15.844 15.844 0 0 1 2.828-2.986l-.483-.575l-5.541.027z"/><path fill="#FFE8B6" d="M26.798 22.118L14.292 7.305c-1.016.836-1.992 1.811-2.822 2.964c-.811 1.126-1.755 2.117-2.735 2.991l1.462 1.731l-.001.001l11.075 13.114a18.71 18.71 0 0 0 2.725-3.003c.83-1.152 1.805-2.126 2.82-2.962l-.019-.023h.001z"/><path fill="#5C913B" d="M14.479 22.555c-1.557-1.844-4.853 1.148-5.793.035c-.455-.539-.162-1.238.436-1.742c1.005-.85 1.73-.355 2.185-.74c.323-.272.306-.605.114-.834c-.446-.527-1.586-.252-2.472.26l-.431-.51a.754.754 0 0 0-1.152.972l.446.529c-.677.898-.907 2.09-.106 3.037c1.496 1.77 4.833-1.172 5.883.072c.364.432.262 1.256-.504 1.902c-1.148.971-2.188.516-2.655.91c-.228.191-.269.555-.026.844c.387.457 1.62.359 2.805-.379c.002.002.002.004.002.006l.487.576a.755.755 0 1 0 1.153-.974l-.487-.576c-.005-.006-.013-.01-.019-.016c.799-.978 1.069-2.267.134-3.372z"/><path fill="#E1E8ED" d="M32.456 32.588c.009-.008.019-.014.028-.021c.068-.068.121-.146.181-.221c.042-.052.089-.102.128-.155c.035-.05.064-.101.096-.152c1.42-2.187.49-5.895-2.321-8.707c-2.812-2.812-6.521-3.742-8.707-2.321c-.052.031-.103.06-.153.096c-.053.039-.104.086-.154.127c-.074.061-.152.113-.221.182c-.009.009-.015.019-.022.028c-.011.011-.024.018-.036.03l.006.005c-1 1.062-1.012 2.705-.006 3.712c1.008 1.008 2.65.994 3.713-.006l.011.012c-.021.02-.044.033-.064.053c-1.059 1.059-1.084 2.748-.059 3.775c1.026 1.025 2.717 1 3.775-.059c.02-.02.033-.043.053-.064l.011.012c-1 1.062-1.013 2.705-.005 3.713c1.007 1.006 2.649.994 3.711-.006l.006.006c.01-.014.018-.027.029-.039z"/><path fill="#CCD6DD" d="M21.277 25.231c.906.905 2.321.979 3.37.261c.439-.75.565-1.463.565-1.686c-2.207 1.646-4.177.009-4.618-.97c-.183.846.039 1.75.683 2.395zm7.299 3.84c.298-.419.529-.824.637-1.098c-1.405 1.288-4.091.345-4.905-1.698c-.358.95-.175 2.044.571 2.79c1.002 1.002 2.634.994 3.697.006zm3.854 3.595l.029-.036c.01-.008.02-.014.028-.022c.069-.068.122-.146.181-.22c.043-.053.089-.102.128-.156c.036-.049.065-.101.097-.152c.065-.1.1-.218.155-.324c-2.528 1.131-4.415-.788-4.944-1.745c-.295.917-.103 1.944.609 2.657c1.006 1.007 2.648.995 3.711-.006l.006.004z"/><path fill="#E1E8ED" d="m13.956 12.498l.028-.022c.069-.068.122-.146.181-.22c.042-.052.088-.101.127-.155c.036-.05.065-.101.097-.152c1.42-2.187.489-5.896-2.322-8.707C9.255.43 5.547-.501 3.36.919c-.051.032-.103.061-.153.097c-.054.039-.103.085-.155.127c-.074.06-.152.112-.22.181c-.009.009-.015.02-.022.028c-.011.01-.025.019-.036.03l.005.005c-1 1.062-1.012 2.705-.005 3.712c1.007 1.007 2.65.995 3.712-.005l.011.011c-.021.019-.044.033-.064.053c-1.059 1.059-1.084 2.748-.058 3.775c1.026 1.027 2.716 1.001 3.775-.058c.02-.02.033-.043.053-.064l.011.011c-1 1.062-1.013 2.705-.005 3.712c1.007 1.007 2.649.995 3.711-.006l.005.006c.011-.011.02-.024.031-.036z"/><path fill="#CCD6DD" d="M2.773 5.1c.906.906 2.321.98 3.37.26c.439-.75.564-1.462.564-1.685c-2.206 1.645-4.177.007-4.617-.972c-.183.847.039 1.752.683 2.397zm7.301 3.838c.297-.419.528-.822.635-1.096c-1.406 1.288-4.092.344-4.905-1.699c-.358.95-.175 2.044.57 2.79c1.004 1.003 2.637.994 3.7.005zm3.851 3.597c.011-.011.02-.024.03-.036l.028-.022c.069-.068.122-.146.181-.22c.042-.052.088-.101.127-.155c.036-.05.065-.101.097-.152c.065-.1.1-.219.155-.325c-2.528 1.131-4.415-.787-4.944-1.744c-.295.917-.103 1.944.609 2.656c1.007 1.007 2.649.995 3.711-.006l.006.004z"/></svg>',
}

const monocleFace: Emoji = {
shortcode: 'monocle_face',
char: '🧐',
Expand Down Expand Up @@ -80,6 +92,8 @@ const rainbow: Emoji = {
}

export {
bat,
moneyWithWings,
monocleFace,
cherryBlossom,
camel,
Expand Down

0 comments on commit 981c920

Please sign in to comment.