From ec1af5ea325fd5a54975214bb766f6d7e03cf4e8 Mon Sep 17 00:00:00 2001 From: Fallen_Breath Date: Fri, 20 Dec 2024 02:41:45 +0800 Subject: [PATCH] test --- package-lock.json | 105 ++++++++++++++++++++++++++++++++++++ src/app/[locale]/layout.tsx | 3 -- src/styles/globals.css | 24 ++++++--- 3 files changed, 122 insertions(+), 10 deletions(-) diff --git a/package-lock.json b/package-lock.json index c341504..757f24f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -722,6 +722,111 @@ "node": ">= 6" } }, + "node_modules/@next/swc-darwin-arm64": { + "version": "15.1.2", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-15.1.2.tgz", + "integrity": "sha512-b9TN7q+j5/7+rGLhFAVZiKJGIASuo8tWvInGfAd8wsULjB1uNGRCj1z1WZwwPWzVQbIKWFYqc+9L7W09qwt52w==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-darwin-x64": { + "version": "15.1.2", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-15.1.2.tgz", + "integrity": "sha512-caR62jNDUCU+qobStO6YJ05p9E+LR0EoXh1EEmyU69cYydsAy7drMcOlUlRtQihM6K6QfvNwJuLhsHcCzNpqtA==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-arm64-gnu": { + "version": "15.1.2", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-15.1.2.tgz", + "integrity": "sha512-fHHXBusURjBmN6VBUtu6/5s7cCeEkuGAb/ZZiGHBLVBXMBy4D5QpM8P33Or8JD1nlOjm/ZT9sEE5HouQ0F+hUA==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-arm64-musl": { + "version": "15.1.2", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-15.1.2.tgz", + "integrity": "sha512-9CF1Pnivij7+M3G74lxr+e9h6o2YNIe7QtExWq1KUK4hsOLTBv6FJikEwCaC3NeYTflzrm69E5UfwEAbV2U9/g==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-x64-gnu": { + "version": "15.1.2", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-15.1.2.tgz", + "integrity": "sha512-tINV7WmcTUf4oM/eN3Yuu/f8jQ5C6AkueZPKeALs/qfdfX57eNv4Ij7rt0SA6iZ8+fMobVfcFVv664Op0caCCg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-x64-musl": { + "version": "15.1.2", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-15.1.2.tgz", + "integrity": "sha512-jf2IseC4WRsGkzeUw/cK3wci9pxR53GlLAt30+y+B+2qAQxMw6WAC3QrANIKxkcoPU3JFh/10uFfmoMDF9JXKg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-win32-arm64-msvc": { + "version": "15.1.2", + "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-15.1.2.tgz", + "integrity": "sha512-wvg7MlfnaociP7k8lxLX4s2iBJm4BrNiNFhVUY+Yur5yhAJHfkS8qPPeDEUH8rQiY0PX3u/P7Q/wcg6Mv6GSAA==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 10" + } + }, "node_modules/@next/swc-win32-x64-msvc": { "version": "15.1.2", "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-15.1.2.tgz", diff --git a/src/app/[locale]/layout.tsx b/src/app/[locale]/layout.tsx index 9077f5d..75bd739 100644 --- a/src/app/[locale]/layout.tsx +++ b/src/app/[locale]/layout.tsx @@ -10,9 +10,6 @@ import { clsx } from "clsx"; import type { Metadata } from 'next' import { NextIntlClientProvider } from "next-intl"; import { getMessages, setRequestLocale } from "next-intl/server"; -// https://github.com/mantinedev/mantine/issues/6109 -// https://mantine.dev/styles/mantine-styles/#css-layers -import '@mantine/core/styles.layer.css' import React from "react"; import styles from './layout.module.css'; import MantineThemeProvider from "./mantine-theme-provider"; diff --git a/src/styles/globals.css b/src/styles/globals.css index 83998cb..4e9e557 100644 --- a/src/styles/globals.css +++ b/src/styles/globals.css @@ -1,11 +1,21 @@ -/* ============= Basic setups ============= */ +/* ============= Layer setups ============= */ +/* https://mantine.dev/styles/mantine-styles/#css-layers */ +/* https://github.com/mantinedev/mantine/issues/6109 */ +/* https://github.com/orgs/mantinedev/discussions/1672#discussioncomment-10777394 */ +/* https://github.com/songkeys/next-app-mantine-tailwind-template/blob/b50ed8d3b8707988493ab4d0f481d5a379a109cf/src/app/globals.css */ -/* https://github.com/orgs/mantinedev/discussions/1672#discussioncomment-7870643 */ -@layer tailwind { - @tailwind base; -} -@tailwind components; -@tailwind utilities; +@layer tw_base, mantine, tw_components, tw_utilities; + +/*noinspection CssInvalidImport*/ +@import "tailwindcss/base" layer(tw_base); +/*noinspection CssInvalidImport*/ +@import "tailwindcss/components" layer(tw_components); +/*noinspection CssInvalidImport*/ +@import "tailwindcss/utilities" layer(tw_utilities); +/*noinspection CssInvalidImport*/ +@import "@mantine/core/styles.layer.css"; + +/* ============= Common tweaks ============= */ .scrollbar-shift-fix { /* https://stackoverflow.com/questions/1417934/how-to-prevent-scrollbar-from-repositioning-web-page/39289453#39289453 */