Init project
commit
4a8049cda0
@ -0,0 +1,43 @@
|
||||
{
|
||||
"name": "Isekai FontAwesome",
|
||||
"namemsg": "isekai-fontawesome-name",
|
||||
"author": "Hyperzlib",
|
||||
"version": "1.0.0",
|
||||
"url": "https://git.isekai.cn/Isekai-Project/mediawiki-extension-IsekaiFontAwesome",
|
||||
"descriptionmsg": "isekai-fontawesome-desc",
|
||||
"license-name": "MIT",
|
||||
"type": "other",
|
||||
"requires": {
|
||||
"MediaWiki": ">=1.35.0"
|
||||
},
|
||||
"MessagesDirs": {
|
||||
"IsekaiFontAwesome": [
|
||||
"i18n"
|
||||
]
|
||||
},
|
||||
"AutoloadClasses": {
|
||||
"Isekai\\FontAwesome\\Hooks": "includes/Hooks.php"
|
||||
},
|
||||
"Hooks": {
|
||||
"BeforePageDisplay": [
|
||||
"Isekai\\FontAwesome\\Hooks::onBeforePageDisplay"
|
||||
]
|
||||
},
|
||||
"ResourceModules": {
|
||||
"ext.fontawesome": {
|
||||
"styles": [
|
||||
"lib/fontawesome/_fontawesome.css",
|
||||
"fontawesome.less"
|
||||
],
|
||||
"targets": [
|
||||
"desktop",
|
||||
"mobile"
|
||||
]
|
||||
}
|
||||
},
|
||||
"ResourceFileModulePaths": {
|
||||
"localBasePath": "modules",
|
||||
"remoteExtPath": "IsekaiFontAwesome/modules"
|
||||
},
|
||||
"manifest_version": 2
|
||||
}
|
@ -0,0 +1,4 @@
|
||||
{
|
||||
"isekai-fontawesome-name": "异世界百科 FontAwesome",
|
||||
"isekai-fontawesome-desc": "在页面中加入 FontAwesome 6 免费版的CSS"
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
<?php
|
||||
namespace Isekai\FontAwesome;
|
||||
|
||||
use OutputPage;
|
||||
use Skin;
|
||||
|
||||
class Hooks {
|
||||
public static function onBeforePageDisplay(OutputPage $out, Skin $skin) {
|
||||
$out->addModuleStyles(['ext.fontawesome']);
|
||||
}
|
||||
}
|
@ -0,0 +1,33 @@
|
||||
:root,
|
||||
:host {
|
||||
--fa-style-family-classic: 'Font Awesome 6 Free';
|
||||
--fa-font-solid: normal 900 1em/1 'Font Awesome 6 Free';
|
||||
--fa-font-regular: normal 400 1em/1 'Font Awesome 6 Free';
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Font Awesome 6 Free';
|
||||
font-style: normal;
|
||||
font-weight: 900;
|
||||
font-display: block;
|
||||
src: url("fonts/fa-solid-900.woff2") format("woff2"), url("fonts/fa-solid-900.ttf") format("truetype");
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Font Awesome 6 Free';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
font-display: block;
|
||||
src: url("fonts/fa-regular-400.woff2") format("woff2"), url("fonts/fa-regular-400.ttf") format("truetype");
|
||||
}
|
||||
|
||||
|
||||
.fas,
|
||||
.fa-solid {
|
||||
font-weight: 900;
|
||||
}
|
||||
|
||||
.far,
|
||||
.fa-regular {
|
||||
font-weight: 400;
|
||||
}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue