Initial release
This commit is contained in:
commit
1d4ab06af1
7 changed files with 724 additions and 0 deletions
176
css/style.css
Normal file
176
css/style.css
Normal file
|
|
@ -0,0 +1,176 @@
|
|||
@import 'markdown.css';
|
||||
|
||||
:root {
|
||||
--bg-color: #f5f5f5;
|
||||
--text-color: #333;
|
||||
--header-color: #2c3e50;
|
||||
--border-color: #dddddd;
|
||||
--code-bg: #f8f9fa;
|
||||
--button-bg: #2c3e50;
|
||||
--button-hover: #34495e;
|
||||
--blockquote-color: #666;
|
||||
--link-color: #3498db;
|
||||
--preview-bg: white;
|
||||
}
|
||||
|
||||
[data-theme="dark"] {
|
||||
--bg-color: #1a1a1a;
|
||||
--text-color: #e0e0e0;
|
||||
--header-color: #60a5fa;
|
||||
--border-color: #404040;
|
||||
--code-bg: #2d2d2d;
|
||||
--button-bg: #60a5fa;
|
||||
--button-hover: #3b82f6;
|
||||
--blockquote-color: #a0a0a0;
|
||||
--link-color: #60a5fa;
|
||||
--preview-bg: #2d2d2d;
|
||||
}
|
||||
|
||||
* {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
|
||||
line-height: 1.6;
|
||||
color: var(--text-color);
|
||||
background-color: var(--bg-color);
|
||||
transition: background-color 0.3s ease, color 0.3s ease;
|
||||
}
|
||||
|
||||
.container {
|
||||
max-width: 1200px;
|
||||
margin: 0 auto;
|
||||
padding: 2rem;
|
||||
}
|
||||
|
||||
header {
|
||||
text-align: center;
|
||||
margin-bottom: 2rem;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
gap: 1rem;
|
||||
}
|
||||
|
||||
.header-content {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
header h1 {
|
||||
color: var(--header-color);
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
|
||||
#theme-toggle {
|
||||
background: none;
|
||||
border: none;
|
||||
cursor: pointer;
|
||||
padding: 0.5rem;
|
||||
color: var(--text-color);
|
||||
border-radius: 50%;
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
#theme-toggle:hover {
|
||||
background: var(--border-color);
|
||||
}
|
||||
|
||||
.sun-icon {
|
||||
display: none;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .sun-icon {
|
||||
display: block;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .moon-icon {
|
||||
display: none;
|
||||
}
|
||||
|
||||
main {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: 2rem;
|
||||
}
|
||||
|
||||
.editor-section {
|
||||
grid-column: 1;
|
||||
}
|
||||
|
||||
.preview-section {
|
||||
grid-column: 2;
|
||||
}
|
||||
|
||||
.html-section {
|
||||
grid-column: 1 / -1;
|
||||
margin-top: 2rem;
|
||||
}
|
||||
|
||||
h2 {
|
||||
color: var(--header-color);
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
|
||||
textarea {
|
||||
width: 100%;
|
||||
height: 400px;
|
||||
padding: 1rem;
|
||||
border: 1px solid var(--border-color);
|
||||
border-radius: 4px;
|
||||
font-family: 'Courier New', Courier, monospace;
|
||||
font-size: 14px;
|
||||
resize: vertical;
|
||||
background-color: var(--preview-bg);
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
#preview {
|
||||
background: var(--preview-bg);
|
||||
padding: 1rem;
|
||||
border: 1px solid var(--border-color);
|
||||
border-radius: 4px;
|
||||
min-height: 400px;
|
||||
}
|
||||
|
||||
button {
|
||||
padding: 0.5rem 1rem;
|
||||
background: var(--button-bg);
|
||||
color: white;
|
||||
border: none;
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
|
||||
button:hover {
|
||||
background: var(--button-hover);
|
||||
}
|
||||
|
||||
#html-output {
|
||||
background: var(--preview-bg);
|
||||
padding: 2px;
|
||||
border: 1px solid var(--border-color);
|
||||
border-radius: 4px;
|
||||
overflow-x: auto;
|
||||
font-family: 'Courier New', Courier, monospace;
|
||||
font-size: 14px;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
main {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
|
||||
.editor-section,
|
||||
.preview-section {
|
||||
grid-column: 1;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue