@@ -26,147 +26,148 @@ import { pluginCustomCopyButton } from "./src/plugins/expressive-code/custom-cop
2626
2727// https://astro.build/config
2828export default defineConfig ( {
29- site : "https://fuwari.vercel.app/" ,
30- base : "/" ,
31- trailingSlash : "always" ,
32- integrations : [
33- tailwind ( {
34- nesting : true ,
35- } ) ,
36- swup ( {
37- theme : false ,
38- animationClass : "transition-swup-" , // see https://swup.js.org/options/#animationselector
39- // the default value `transition-` cause transition delay
40- // when the Tailwind class `transition-all` is used
41- containers : [ "main" , "#toc" ] ,
42- smoothScrolling : true ,
43- cache : true ,
44- preload : true ,
45- accessibility : true ,
46- updateHead : true ,
47- updateBodyClass : false ,
48- globalInstance : true ,
49- } ) ,
50- icon ( {
51- include : {
52- "preprocess: vitePreprocess()," : [ "*" ] ,
53- "fa6-brands" : [ "*" ] ,
54- "fa6-regular" : [ "*" ] ,
55- "fa6-solid" : [ "*" ] ,
56- } ,
57- } ) ,
58- expressiveCode ( {
59- themes : [ expressiveCodeConfig . theme , expressiveCodeConfig . theme ] ,
60- plugins : [
61- pluginCollapsibleSections ( ) ,
62- pluginLineNumbers ( ) ,
63- pluginLanguageBadge ( ) ,
64- pluginCustomCopyButton ( )
65- ] ,
66- defaultProps : {
67- wrap : true ,
68- overridesByLang : {
69- 'shellsession' : {
70- showLineNumbers : false ,
71- } ,
72- } ,
73- } ,
74- styleOverrides : {
75- codeBackground : "var(--codeblock-bg)" ,
76- borderRadius : "0.75rem" ,
77- borderColor : "none" ,
78- codeFontSize : "0.875rem" ,
79- codeFontFamily : "'JetBrains Mono Variable', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace" ,
80- codeLineHeight : "1.5rem" ,
81- frames : {
82- editorBackground : "var(--codeblock-bg)" ,
83- terminalBackground : "var(--codeblock-bg)" ,
84- terminalTitlebarBackground : "var(--codeblock-topbar-bg)" ,
85- editorTabBarBackground : "var(--codeblock-topbar-bg)" ,
86- editorActiveTabBackground : "none" ,
87- editorActiveTabIndicatorBottomColor : "var(--primary)" ,
88- editorActiveTabIndicatorTopColor : "none" ,
89- editorTabBarBorderBottomColor : "var(--codeblock-topbar-bg)" ,
90- terminalTitlebarBorderBottomColor : "none"
91- } ,
92- textMarkers : {
93- delHue : 0 ,
94- insHue : 180 ,
95- markHue : 250
96- }
97- } ,
98- frames : {
99- showCopyToClipboardButton : false ,
100- }
101- } ) ,
102- svelte ( ) ,
103- sitemap ( ) ,
104- ] ,
105- markdown : {
106- remarkPlugins : [
107- remarkMath ,
108- remarkReadingTime ,
109- remarkExcerpt ,
110- remarkGithubAdmonitionsToDirectives ,
111- remarkDirective ,
112- remarkSectionize ,
113- parseDirectiveNode ,
114- ] ,
115- rehypePlugins : [
116- rehypeKatex ,
117- rehypeSlug ,
118- [
119- rehypeComponents ,
120- {
121- components : {
122- github : GithubCardComponent ,
123- note : ( x , y ) => AdmonitionComponent ( x , y , "note" ) ,
124- tip : ( x , y ) => AdmonitionComponent ( x , y , "tip" ) ,
125- important : ( x , y ) => AdmonitionComponent ( x , y , "important" ) ,
126- caution : ( x , y ) => AdmonitionComponent ( x , y , "caution" ) ,
127- warning : ( x , y ) => AdmonitionComponent ( x , y , "warning" ) ,
128- } ,
129- } ,
130- ] ,
131- [
132- rehypeAutolinkHeadings ,
133- {
134- behavior : "append" ,
135- properties : {
136- className : [ "anchor" ] ,
137- } ,
138- content : {
139- type : "element" ,
140- tagName : "span" ,
141- properties : {
142- className : [ "anchor-icon" ] ,
143- "data-pagefind-ignore" : true ,
144- } ,
145- children : [
146- {
147- type : "text" ,
148- value : "#" ,
149- } ,
150- ] ,
151- } ,
152- } ,
153- ] ,
154- ] ,
155- } ,
156- vite : {
157- build : {
158- rollupOptions : {
159- onwarn ( warning , warn ) {
160- // temporarily suppress this warning
161- if (
162- warning . message . includes ( "is dynamically imported by" ) &&
163- warning . message . includes ( "but also statically imported by" )
164- ) {
165- return ;
166- }
167- warn ( warning ) ;
168- } ,
169- } ,
170- } ,
171- } ,
29+ site : "https://iftype.github.io" ,
30+ base : "/" ,
31+ trailingSlash : "always" ,
32+ integrations : [
33+ tailwind ( {
34+ nesting : true ,
35+ } ) ,
36+ swup ( {
37+ theme : false ,
38+ animationClass : "transition-swup-" , // see https://swup.js.org/options/#animationselector
39+ // the default value `transition-` cause transition delay
40+ // when the Tailwind class `transition-all` is used
41+ containers : [ "main" , "#toc" ] ,
42+ smoothScrolling : true ,
43+ cache : true ,
44+ preload : true ,
45+ accessibility : true ,
46+ updateHead : true ,
47+ updateBodyClass : false ,
48+ globalInstance : true ,
49+ } ) ,
50+ icon ( {
51+ include : {
52+ "preprocess: vitePreprocess()," : [ "*" ] ,
53+ "fa6-brands" : [ "*" ] ,
54+ "fa6-regular" : [ "*" ] ,
55+ "fa6-solid" : [ "*" ] ,
56+ } ,
57+ } ) ,
58+ expressiveCode ( {
59+ themes : [ expressiveCodeConfig . theme , expressiveCodeConfig . theme ] ,
60+ plugins : [
61+ pluginCollapsibleSections ( ) ,
62+ pluginLineNumbers ( ) ,
63+ pluginLanguageBadge ( ) ,
64+ pluginCustomCopyButton ( ) ,
65+ ] ,
66+ defaultProps : {
67+ wrap : true ,
68+ overridesByLang : {
69+ shellsession : {
70+ showLineNumbers : false ,
71+ } ,
72+ } ,
73+ } ,
74+ styleOverrides : {
75+ codeBackground : "var(--codeblock-bg)" ,
76+ borderRadius : "0.75rem" ,
77+ borderColor : "none" ,
78+ codeFontSize : "0.875rem" ,
79+ codeFontFamily :
80+ "'JetBrains Mono Variable', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace" ,
81+ codeLineHeight : "1.5rem" ,
82+ frames : {
83+ editorBackground : "var(--codeblock-bg)" ,
84+ terminalBackground : "var(--codeblock-bg)" ,
85+ terminalTitlebarBackground : "var(--codeblock-topbar-bg)" ,
86+ editorTabBarBackground : "var(--codeblock-topbar-bg)" ,
87+ editorActiveTabBackground : "none" ,
88+ editorActiveTabIndicatorBottomColor : "var(--primary)" ,
89+ editorActiveTabIndicatorTopColor : "none" ,
90+ editorTabBarBorderBottomColor : "var(--codeblock-topbar-bg)" ,
91+ terminalTitlebarBorderBottomColor : "none" ,
92+ } ,
93+ textMarkers : {
94+ delHue : 0 ,
95+ insHue : 180 ,
96+ markHue : 250 ,
97+ } ,
98+ } ,
99+ frames : {
100+ showCopyToClipboardButton : false ,
101+ } ,
102+ } ) ,
103+ svelte ( ) ,
104+ sitemap ( ) ,
105+ ] ,
106+ markdown : {
107+ remarkPlugins : [
108+ remarkMath ,
109+ remarkReadingTime ,
110+ remarkExcerpt ,
111+ remarkGithubAdmonitionsToDirectives ,
112+ remarkDirective ,
113+ remarkSectionize ,
114+ parseDirectiveNode ,
115+ ] ,
116+ rehypePlugins : [
117+ rehypeKatex ,
118+ rehypeSlug ,
119+ [
120+ rehypeComponents ,
121+ {
122+ components : {
123+ github : GithubCardComponent ,
124+ note : ( x , y ) => AdmonitionComponent ( x , y , "note" ) ,
125+ tip : ( x , y ) => AdmonitionComponent ( x , y , "tip" ) ,
126+ important : ( x , y ) => AdmonitionComponent ( x , y , "important" ) ,
127+ caution : ( x , y ) => AdmonitionComponent ( x , y , "caution" ) ,
128+ warning : ( x , y ) => AdmonitionComponent ( x , y , "warning" ) ,
129+ } ,
130+ } ,
131+ ] ,
132+ [
133+ rehypeAutolinkHeadings ,
134+ {
135+ behavior : "append" ,
136+ properties : {
137+ className : [ "anchor" ] ,
138+ } ,
139+ content : {
140+ type : "element" ,
141+ tagName : "span" ,
142+ properties : {
143+ className : [ "anchor-icon" ] ,
144+ "data-pagefind-ignore" : true ,
145+ } ,
146+ children : [
147+ {
148+ type : "text" ,
149+ value : "#" ,
150+ } ,
151+ ] ,
152+ } ,
153+ } ,
154+ ] ,
155+ ] ,
156+ } ,
157+ vite : {
158+ build : {
159+ rollupOptions : {
160+ onwarn ( warning , warn ) {
161+ // temporarily suppress this warning
162+ if (
163+ warning . message . includes ( "is dynamically imported by" ) &&
164+ warning . message . includes ( "but also statically imported by" )
165+ ) {
166+ return ;
167+ }
168+ warn ( warning ) ;
169+ } ,
170+ } ,
171+ } ,
172+ } ,
172173} ) ;
0 commit comments