Skip to content

Commit

Permalink
feat: add favicon to cbth (Shopify#45)
Browse files Browse the repository at this point in the history
## Context

Add basic favicon to CBTH

## Changes

Added the favicon and linked to the file(s)

## Screenshot

![Screenshot 2023-06-19 at 15 49
32](https://github.com/code-internet-applications/cbt-hydrogen/assets/2558163/8c5b4047-86dc-470b-99ee-e3e360e6c1a2)

## Paperwork

[SCH-30](https://codeinternetapplications.atlassian.net/browse/SCH-30)

## Checklist

- [x] My code follows the style guidelines of this project
- [x] I've performed a self-review of my own code
- [x] I've added a changeset if this PR contains user-facing or
noteworthy changes
- [x] I've commented my code, particularly in hard-to-understand areas
- [x] I've made corresponding changes to the documentation
- [x] I've tested my code for breaking changes and added the
corresponding
      footer in this PR if needed


[SCH-30]:
https://codeinternetapplications.atlassian.net/browse/SCH-30?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
  • Loading branch information
remcolakens committed Jun 19, 2023
1 parent 2b62904 commit c1ef688
Show file tree
Hide file tree
Showing 16 changed files with 90 additions and 31 deletions.
38 changes: 35 additions & 3 deletions apps/code-base-theme/app/root.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,17 @@ import {
useLoaderData,
} from '@remix-run/react';
import type { Shop } from '@shopify/hydrogen/storefront-api-types';
import { type LinksFunction, type LoaderArgs } from '@shopify/remix-oxygen';
import favicon from '../public/favicon.svg';

import {
V2_MetaFunction,
type LinksFunction,
type LoaderArgs,
} from '@shopify/remix-oxygen';
import appleTouchIcon from '../public/apple-touch-icon.png';
import appleTouchIcon16 from '../public/favicon-16x16.png';
import appleTouchIcon32 from '../public/favicon-32x32.png';
import safariPinnedTab from '../public/safari-pinned-tab.svg';
import siteWebmanifest from '../public/site.webmanifest';
import styles from './styles/tailwind.css';

export const links: LinksFunction = () => {
Expand All @@ -34,7 +43,30 @@ export const links: LinksFunction = () => {
rel: 'preconnect',
href: 'https://fonts.gstatic.com',
},
{ rel: 'icon', type: 'image/svg+xml', href: favicon },
{ rel: 'apple-touch-icon', sizes: '180x180', href: appleTouchIcon },
{ rel: 'icon', type: 'image/png', sizes: '32x32', href: appleTouchIcon32 },
{ rel: 'icon', type: 'image/png', sizes: '16x16', href: appleTouchIcon16 },
{ rel: 'manifest', href: siteWebmanifest },
{ rel: 'mask-icon', href: safariPinnedTab, color: '#000000' },
];
};

export const meta: V2_MetaFunction = () => {
return [
{ title: 'Code Base Theme Hydrogen' },
{
name: 'description',
content:
"🚀 Code Base Theme Hydrogen: Simple, modular and accessible components for Shopify's headless commerce ",
},
{
name: 'msapplication-TileColor',
content: '#000000',
},
{
name: 'theme-color',
content: '#ffffff',
},
];
};

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/code-base-theme/public/apple-touch-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 9 additions & 0 deletions apps/code-base-theme/public/browserconfig.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<browserconfig>
<msapplication>
<tile>
<square150x150logo src="/mstile-150x150.png"/>
<TileColor>#000000</TileColor>
</tile>
</msapplication>
</browserconfig>
Binary file added apps/code-base-theme/public/favicon-16x16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/code-base-theme/public/favicon-32x32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/code-base-theme/public/favicon.ico
Binary file not shown.
28 changes: 0 additions & 28 deletions apps/code-base-theme/public/favicon.svg

This file was deleted.

Binary file added apps/code-base-theme/public/mstile-144x144.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/code-base-theme/public/mstile-150x150.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/code-base-theme/public/mstile-310x150.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/code-base-theme/public/mstile-310x310.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/code-base-theme/public/mstile-70x70.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 27 additions & 0 deletions apps/code-base-theme/public/safari-pinned-tab.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
19 changes: 19 additions & 0 deletions apps/code-base-theme/public/site.webmanifest
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"name": "",
"short_name": "",
"icons": [
{
"src": "/android-chrome-192x192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "/android-chrome-512x512.png",
"sizes": "512x512",
"type": "image/png"
}
],
"theme_color": "#ffffff",
"background_color": "#ffffff",
"display": "standalone"
}

0 comments on commit c1ef688

Please sign in to comment.