iqijun_obsidian-image-share/styles.css
xingguishuai b23fa9f70f css
2025-02-07 20:15:18 +08:00

194 lines
4 KiB
CSS

/*
This CSS file will be included with your plugin, and
available in the app when your plugin is enabled.
If your plugin does not need CSS, delete this file.
*/
.image-share-modal {
max-width: none;
max-height: none;
}
.image-share-modal .resizable-container {
position: relative;
width: 680px;
background: var(--background-primary);
border-radius: 12px;
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
overflow: hidden;
}
.image-share-modal .resize-handle {
position: absolute;
right: 0;
bottom: 0;
width: 20px;
height: 20px;
cursor: se-resize;
background: var(--interactive-accent);
clip-path: polygon(100% 0, 100% 100%, 0 100%);
opacity: 0.6;
transition: opacity 0.2s ease;
}
.image-share-modal .resize-handle:hover {
opacity: 1;
}
.image-share-modal .header {
display: flex;
flex-direction: column;
gap: 16px;
margin-bottom: 20px;
}
.image-share-modal .image-preview-container {
height: 100%;
display: flex;
flex-direction: column;
padding: 20px 24px;
box-sizing: border-box;
gap: 16px;
position: relative;
}
.image-share-modal .canvas-container {
display: flex;
justify-content: center;
align-items: flex-start;
padding: 16px;
background: var(--background-secondary);
border-radius: 8px;
min-height: 200px;
margin-bottom: 60px;
}
.image-share-modal h2 {
margin: 0;
color: var(--text-normal);
font-size: 1.2em;
font-weight: 600;
padding: 4px 0;
}
.image-share-modal .download-button {
position: absolute;
bottom: 24px;
right: 24px;
background: var(--interactive-accent);
border: none;
border-radius: 50%;
width: 48px;
height: 48px;
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
transition: all 0.2s ease;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
padding: 12px;
color: var(--text-on-accent);
z-index: 100;
}
.image-share-modal .download-button:hover {
transform: translateY(-2px);
box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}
.image-share-modal .download-button svg {
width: 24px;
height: 24px;
}
.image-share-modal canvas {
max-width: 100%;
height: auto;
border-radius: 8px;
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
}
.image-share-modal .template-selector {
display: flex;
gap: 8px;
}
.image-share-modal .template-button {
padding: 8px 16px;
border: 1px solid var(--interactive-accent);
border-radius: 6px;
background: transparent;
color: var(--interactive-accent);
cursor: pointer;
transition: all 0.2s ease;
font-size: 14px;
font-weight: 500;
}
.image-share-modal .template-button:hover {
background: var(--interactive-accent);
color: var(--text-on-accent);
}
.image-share-modal .template-button.active {
background: var(--interactive-accent);
color: var(--text-on-accent);
}
.markdown-preview-view {
font-family: 'PingFang SC', -apple-system, BlinkMacSystemFont, sans-serif;
line-height: 1.6;
overflow: visible;
word-break: break-word;
white-space: pre-wrap;
}
.markdown-preview-view h1,
.markdown-preview-view h2,
.markdown-preview-view h3 {
margin: 0.5em 0;
font-weight: 600;
}
.markdown-preview-view h1 { font-size: 1.5em; }
.markdown-preview-view h2 { font-size: 1.3em; }
.markdown-preview-view h3 { font-size: 1.1em; }
.markdown-preview-view p {
margin: 0.5em 0;
}
.markdown-preview-view strong {
font-weight: 600;
}
.markdown-preview-view em {
font-style: italic;
}
.markdown-preview-view ul,
.markdown-preview-view ol {
margin: 0.5em 0;
padding-left: 1.5em;
}
.markdown-preview-view li {
margin: 0.2em 0;
}
.markdown-preview-view code {
font-family: monospace;
background: rgba(0,0,0,0.1);
padding: 0.2em 0.4em;
border-radius: 3px;
}
.markdown-preview-view blockquote {
border-left: 3px solid currentColor;
margin: 0.5em 0;
padding-left: 1em;
opacity: 0.8;
}