Skip to content
This repository was archived by the owner on Feb 10, 2025. It is now read-only.

Commit

Permalink
use inter font
Browse files Browse the repository at this point in the history
  • Loading branch information
timche committed Jan 27, 2024
1 parent 6d33f39 commit 3bff571
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 10 deletions.
18 changes: 9 additions & 9 deletions src/content/features/add-match-room-skin-of-the-match.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import {
import { getMatch, getSelf } from '../helpers/faceit-api'
import { isSupportedGame } from '../helpers/games'
import { getRoomId } from '../helpers/match-room'
import tailwindStyles from 'tailwindInline:../styles.css'

const FEATURE_ATTRIBUTE = 'skin-of-the-match'

Expand Down Expand Up @@ -156,14 +157,7 @@ export default async () => {
)

const skinOfTheMatchElement = (
<div
className="tooltipTrigger spotlightTrigger skinImageTrigger"
style={{
position: 'relative',
fontFamily:
'ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji',
}}
>
<div className="relative tooltipTrigger spotlightTrigger skinImageTrigger">
<span
onClick={() => {
browser.runtime.sendMessage({
Expand Down Expand Up @@ -254,6 +248,7 @@ export default async () => {
style={{
fontWeight: 'bold',
}}
className="text-white"
>
Skin Of The Match
</div>
Expand Down Expand Up @@ -367,7 +362,7 @@ export default async () => {
{skinOfTheMatchPlayer.nickname}
</div>
</div>
<div style={{ fontWeight: 'bold' }}>
<div style={{ fontWeight: 'bold' }} className="text-white">
{skinOfTheMatch.skin.name}
</div>
<div style={{ color: 'rgba(255,255,255,0.6)', fontSize: 10 }}>
Expand Down Expand Up @@ -412,6 +407,11 @@ export default async () => {
const skinOfTheMatchWrapper = document.createElement('div')
skinOfTheMatchWrapper.attachShadow({ mode: 'open' })

const tailwindStylesElement = document.createElement('style')
tailwindStylesElement.textContent = tailwindStyles

skinOfTheMatchWrapper.shadowRoot.appendChild(tailwindStylesElement)

skinOfTheMatchWrapper.shadowRoot.appendChild(styles)

skinOfTheMatchWrapper.shadowRoot.appendChild(skinOfTheMatchElement)
Expand Down
3 changes: 2 additions & 1 deletion src/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@
{
"run_at": "document_end",
"matches": ["https://www.faceit.com/*"],
"js": ["content.js"]
"js": ["content.js"],
"css": ["fonts.css"]
}
],
"action": {
Expand Down
1 change: 1 addition & 0 deletions src/shared/faceit-beta.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ export function registerFaceitBetaContentScript() {
runAt: 'document_start',
matches: [FACEIT_BETA_CONTENT_SCRIPT_MATCH_PATTERN],
js: ['content.js'],
css: ['fonts.css'],
},
])
}

0 comments on commit 3bff571

Please sign in to comment.