introduce BASE_URL to the app and set it to /kgstudio/.

This commit is contained in:
Xiaohan-Tian
2025-08-11 22:35:51 -07:00
parent af9eca8fee
commit bf085dacf2
8 changed files with 17 additions and 16 deletions
+1 -1
View File
@@ -65,7 +65,7 @@ const InstrumentSelection: React.FC = () => {
<div className="instrument-selection-top">
<div className="instrument-preview">
<img
src={`/resources/instruments/${previewImage}`}
src={`${import.meta.env.BASE_URL}resources/instruments/${previewImage}`}
alt={previewAlt.toString()}
width={256}
height={256}
+1 -1
View File
@@ -675,7 +675,7 @@ const Toolbar: React.FC = () => {
<div className="toolbar">
<div className="toolbar-left">
<div className="logo-container">
<img src="/logo.png" alt="DAW Logo" className="logo" />
<img src={`${import.meta.env.BASE_URL}logo.png`} alt="DAW Logo" className="logo" />
</div>
<div
className="project-name"
+1 -1
View File
@@ -247,7 +247,7 @@ const TrackInfoItem: React.FC<TrackInfoItemProps> = ({
<div className="track-name-and-volume">
<div className="instrument-image">
<img
src={`/resources/instruments/${String(FLUIDR3_INSTRUMENT_MAP[currentInstrument as keyof typeof FLUIDR3_INSTRUMENT_MAP]?.image || 'piano.png')}`}
src={`${import.meta.env.BASE_URL}resources/instruments/${String(FLUIDR3_INSTRUMENT_MAP[currentInstrument as keyof typeof FLUIDR3_INSTRUMENT_MAP]?.image || 'piano.png')}`}
alt={String(FLUIDR3_INSTRUMENT_MAP[currentInstrument as keyof typeof FLUIDR3_INSTRUMENT_MAP]?.displayName || currentInstrument)}
width="64"
height="64"