Skip to content

Commit

Permalink
スタイルシートが適用されない
Browse files Browse the repository at this point in the history
  • Loading branch information
huideyeren committed Jul 5, 2024
1 parent 35d2e9e commit afa2f31
Show file tree
Hide file tree
Showing 6 changed files with 49 additions and 512 deletions.
18 changes: 10 additions & 8 deletions sass/common/_contents.scss
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ figure > img[src$='.jpeg'] {
}

p > img, div > img, section > img {
width: auto;
max-width: $content-width;
max-height: $content-height;
max-inline-size: 100%;
max-block-size: 100vb;
object-fit: contain;
}

/* 奥付 */
Expand Down Expand Up @@ -108,11 +108,13 @@ div.note, div.memo, div.tip, div.info, div.warning, div.important, div.caution,
}

img.max {
margin: 0 !important;
max-width: 100vw;
width: auto;
max-height: 100vh;
height: auto;
margin-top: 0 !important;
margin-bottom: 0 !important;
margin-left: 0 !important;
margin-right: 0 !important;
max-inline-size: 100%;
max-block-size: 100vb;
object-fit: contain;
}

pre {
Expand Down
25 changes: 24 additions & 1 deletion sass/common/_format.scss
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ html {
}

@page {
size: $paper-width $paper-height;
size: $paper-size;
bleed: $bleed-size;
// 行送り * 行数
width: $content-width;
// フォントサイズ * 文字数
Expand Down Expand Up @@ -51,6 +52,9 @@ html {
}
}

@page :first { margin: 0 !important; }
@page :last { margin: 0 !important; }

@page :right {

margin-left: $nodo;
Expand Down Expand Up @@ -83,6 +87,11 @@ html {
}

@page cover {
size: $paper-size;
bleed: $bleed-size;
width: $paper-width;
height: $paper-height;
marks: $marks;
margin-top: 0 !important;
margin-bottom: 0 !important;
margin-right: 0 !important;
Expand Down Expand Up @@ -110,6 +119,11 @@ html {
}

@page title {
size: $paper-size;
bleed: $bleed-size;
width: $paper-width;
height: $paper-height;
marks: $marks;
margin-top: 0 !important;
margin-bottom: 0 !important;
margin-right: 0 !important;
Expand Down Expand Up @@ -150,6 +164,10 @@ html {
}

@page colophon {
size: $paper-size;
width: $paper-width;
height: $paper-height;
marks: $marks;
margin-top: 0 !important;
margin-bottom: 0 !important;
margin-right: 0 !important;
Expand All @@ -176,6 +194,11 @@ html {
}

@page backcover {
size: $paper-size;
bleed: $bleed-size;
width: $paper-width;
height: $paper-height;
marks: $marks;
margin-top: 0 !important;
margin-bottom: 0 !important;
margin-right: 0 !important;
Expand Down
5 changes: 5 additions & 0 deletions sass/vivliostyle-a4.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ $koguchi: 12mm;
// ノド
$nodo: 18mm;

//紙のサイズ
$paper-size: a4;
//塗り足しサイズ
$bleed-size: 3mm;

//紙の横幅
$paper-width: 210mm;
//紙の縦幅
Expand Down
5 changes: 5 additions & 0 deletions sass/vivliostyle-a5.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ $koguchi: 12mm;
// ノド
$nodo: 18mm;

//紙のサイズ
$paper-size: a5;
//塗り足しサイズ
$bleed-size: 3mm;

//紙の横幅
$paper-width: 148mm;
//紙の縦幅
Expand Down
5 changes: 5 additions & 0 deletions sass/vivliostyle-a6.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ $koguchi: 12mm;
// ノド
$nodo: 18mm;

//紙のサイズ
$paper-size: a6;
//塗り足しサイズ
$bleed-size: 3mm;

//紙の横幅
$paper-width: 105mm;
//紙の縦幅
Expand Down
Loading

0 comments on commit afa2f31

Please sign in to comment.