From adb574c02994b40ef68b115cf3565d32ec8eb9cb Mon Sep 17 00:00:00 2001 From: albyp Date: Wed, 1 Nov 2023 17:14:24 +0800 Subject: [PATCH] Added h2/h3 functions --- index.html | 2 ++ script.js | 2 ++ styles.css | 10 ++++++++++ 3 files changed, 14 insertions(+) diff --git a/index.html b/index.html index 0ef39b9..eeedca3 100644 --- a/index.html +++ b/index.html @@ -28,6 +28,8 @@
+ + diff --git a/script.js b/script.js index c1e7a6c..f176ee6 100644 --- a/script.js +++ b/script.js @@ -7,6 +7,8 @@ function updatePreview() { content = content.replace(/\n/g, '
'); content = content.replace(/\[h1\](.*?)\[\/h1\]/g, '

$1

'); + content = content.replace(/\[h2\](.*?)\[\/h2\]/g, '

$1

'); + content = content.replace(/\[h3\](.*?)\[\/h3\]/g, '

$1

'); content = content.replace(/\[b\](.*?)\[\/b\]/g, '$1'); content = content.replace(/\[u\](.*?)\[\/u\]/g, '$1'); content = content.replace(/\[i\](.*?)\[\/i\]/g, '$1'); diff --git a/styles.css b/styles.css index 56fc057..e55def5 100644 --- a/styles.css +++ b/styles.css @@ -157,6 +157,16 @@ h1 { color: #5aa9d6; } +h2 { + font-weight: 300; + color: #5aa9d6; +} + +h3 { + font-weight: 200; + color: #5aa9d6; +} + .quote-modal { display: none; position: fixed;