mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-17 17:51:24 +01:00
refactor(es modules): migrate colorUtils
This commit is contained in:
parent
364f33975f
commit
b425a9daf6
12 changed files with 63 additions and 49 deletions
|
|
@ -1,6 +1,7 @@
|
|||
import {restoreDefaultEvents} from "/src/scripts/events";
|
||||
import {findAll, findCell, getPackPolygon, isLand} from "/src/utils/graphUtils";
|
||||
import {tip, showMainTip, clearMainTip} from "/src/scripts/tooltips";
|
||||
import {getRandomColor} from "/src/utils/colorUtils";
|
||||
|
||||
export function editBiomes() {
|
||||
if (customization) return;
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@ import {restoreDefaultEvents} from "/src/scripts/events";
|
|||
import {findAll, findCell, getPackPolygon, isLand} from "/src/utils/graphUtils";
|
||||
import {unique} from "/src/utils/arrayUtils";
|
||||
import {tip, showMainTip, clearMainTip} from "/src/scripts/tooltips";
|
||||
import {getRandomColor} from "/src/utils/colorUtils";
|
||||
|
||||
export function editProvinces() {
|
||||
if (customization) return;
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ const customPresetPrefix = "fmgStyle_";
|
|||
document.getElementById("stylePreset").innerHTML = options;
|
||||
}
|
||||
|
||||
async function applyStyleOnLoad() {
|
||||
export async function applyStyleOnLoad() {
|
||||
const desiredPreset = localStorage.getItem("presetStyle") || "default";
|
||||
const styleData = await getStylePreset(desiredPreset);
|
||||
const [appliedPreset, style] = styleData;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue