模板指南(通用/翻譯)

評分: 0+x

這是一篇給翻譯者的模板指南。
本頁面將講解有關於模板(module)的搬運以及內容更動。


模板是一種決定頁面風格的css編碼,一般情況下翻譯者僅需要注意以下幾個重點即可翻譯成繁中:

  • 模板宣告([[module css]])
  • 頭條(header)

若您想更進一步了解並創造屬於您的模板,請至模板指南(自定義)

模板宣告

模板宣告通常可以是[[module css]],[[include]]。您必須藉由點擊您要翻譯的該頁面下方之+選項>編輯源代碼方能看到他所使用的前述之宣告。前者模板編碼可能會是在您要翻譯的該頁面上,也有可能在其他網站上,通常會在wikidot所屬的網站上,而後者通常模板編碼位於[[include 模板頁網址]]內的模板頁網址裡頭。

[[module css]]

請觀察以下"SPC主題"模板編碼並去這裡觀察標題:

/*
    SPC Theme
    [2018 Wikidot Theme]
    Based on Aelanna's Sigma 9 and Greenwolf's Third Law and djkaktus' Darkbody Theme
    Edited by PeppersGhost for the Doomsday Contest 
    SPC logo by BABAAL from CN branch.
*/
 
a:visited {
    color: #176784;
}
 
/* HEADER */
#header {
    height: 140px;
    position: relative;
    z-index: 10;
    padding-bottom: 30px; /* FOR MENU */
    background: url(http://scp-wiki.wdfiles.com/local--files/spc-001/SPCLogo50.png) 10px 35px no-repeat;
}
 
#header h1 a {
    content: "SPC Database";
}
 
#header h1 a::before {
    content: "SPC Database";
}
 
#header h1 a span{
    display: block;
    content: "";
    visibility: hidden;
}
 
#header h2 {
    margin-left: 120px;
    padding: 0;
    clear: left;
    float: left;
    font-size: 105%;
    max-height: 38px;
}
#header h2 span {
    display: block;
    margin: 0;
    padding: 19px 0;
    line-height: 0px;
    max-height: 0px;
    font-weight: bold;
    color: transparent;
    text-shadow: none;
}
#header h2 span::before {
    content: "Shark Punching Center";
    display: block;
    margin: 0;
    padding: 0px 0;
    line-height: 0px;
    max-height: 0px;
    font-weight: bold;
    color: #f0f0c0;
    text-shadow: 1px 1px 1px #000;
    text-shadow: 1px 1px 1px rgba(0,0,0,.8);
}
 
div#container-wrap {
    background-image: url(http://www.scp-wiki.net/local--files/component:spc-theme/SPCWrapper.jpg);
}
 
/* Source: https://www.flickr.com/photos/telemax/2818520042 */
 
/* SIDEBAR */
#side-bar .side-block {
    border-color: #0e7dcd;
    box-shadow: 0 2px 6px rgba(0,0,51,.5);
}
 
#side-bar img {
  width:13px;
  height:13px;
  box-sizing:border-box;
  padding-left: 13px;
  background: url(http://www.scp-wiki.net/local--files/component:spc-theme/FirstIconTransparent.png) left top no-repeat;
}
/* Source: https://commons.wikimedia.org/wiki/File:Noun_project_758.svg */
 
#side-bar .heading {
    color: #0e7dcd;
    border-bottom: solid 1px #0e7dcd;
}
 
#side-bar div.menu-item.inactive a {
    color: #0b65c0;
}
 
#side-bar a:visited {
    color: #0c499c;
}
 
#side-bar div.menu-item .sub-text {
    color: #0b65c0;
}
 
#side-bar .collapsible-block-unfolded-link {
    border-bottom: solid 1px #0b65c0;
}
#side-bar .collapsible-block-unfolded-link .collapsible-block-link {
    color: #0b65c0;
}
 
.interwiki_title {
    color: #0b65c0;
}
 
.interwiki_entry a {
    color: #0b65c0;
}
 
/* LINKS */
 
a {
    color: #0c499c;
    text-decoration: none;
    background: transparent;
}
a.newpage {
    color: #0c499c;
    text-decoration: none;
    background: transparent;
}
 
/* INFO PANE */
.rate-box-with-credit-button {
    background-color: #132639 !important;
    border-color: #0b65c0 !important;
}
 
.page-rate-widget-box{
    border: none !important;
}
 
.rate-box-with-credit-button .fa-info {
    border-color: #0b65c0 !important;
    color: #f3f3f3 !important;
}
 
.rate-box-with-credit-button .fa-info:hover {
    color: #3182d3 !important;
}
 
.rate-box-with-credit-button .cancel {
    border: none !important;
}
 
.close-credits{
    filter: hue-rotate(210deg);
}
 
.modalbox {
    box-shadow: 0px 1px 10px rgb(39,130,221,0.3) !important;
}
 
/* RATING MODULE */
.page-rate-widget-box .rate-points {
    background-color: #132639 !important;
    border: solid 1px #0b65c0;
}
.page-rate-widget-box .rateup,
.page-rate-widget-box .ratedown {
    background-color: 132639;
    border-top: solid 1px #0b65c0;
    border-bottom: solid 1px #0b65c0;
    font-weight: bold;
}
.page-rate-widget-box .rateup a,
.page-rate-widget-box .ratedown a {
    background: 132639;
    color: #0b65c0;
    padding: 0 4px;
    margin: 0 1px;
}
.page-rate-widget-box .rateup a:hover,
.page-rate-widget-box .ratedown a:hover {
    background: #132639;
    color: #0b65c0;
    text-decoration: none;
}
.page-rate-widget-box .cancel {
    background-color: #132639;
    border: solid 1px #0b65c0;
    border-left: 0;
    border-radius: 0 5px 5px 0;
}
.page-rate-widget-box .cancel a {
    background: transparent;
    text-transform: uppercase;
    color: #0b65c0;
}
.page-rate-widget-box .cancel a:hover {
    border-radius: 0 3px 3px 0;
    background: #132639;
    color: #fffff0;
    text-decoration: none;
}
 
/* PAGE TITLEs */
h1, #page-title {
    color: #0c499c;
}
 
/* NAV DROPDOWN */
 
#top-bar ul li.sfhover a,
#top-bar ul li:hover a {
    color: #0c499c;
}
 
/* SEARCH BAR */
#search-top-box-input {
    border: solid 1px #0b65c0;
    background-color: #132639;
}
 
#search-top-box-input:hover,
#search-top-box-input:focus {
    border: solid 1px #0b65c0;
    background-color: #132639;
}
 
#search-top-box-form input[type=submit] {
    border: solid 1px #0b65c0;
    background-color: #132639;
    color: #0b2447;
    background: linear-gradient(to bottom, #2373cd,#319ec2,#183291);
}
 
#search-top-box-form input[type=submit]:hover,
#search-top-box-form input[type=submit]:focus {
    border: solid 1px #0b65c0;
    color: #0b2447;
    background-color: #132639;
    background: linear-gradient(to bottom, #2373cd,#319ec2,#183291);
}
 
.scpnet-interwiki-frame{
     filter: hue-rotate(260deg) brightness(150%);
}
 
/* LOGIN STATUS */
#login-status ul a {
    color: #0c499c;
}
 
/* Changes background for collapsed sidebar */
@media (max-width: 767px) {
#side-bar{background-color: #0b65c0}
}


看完了?您注意到了嗎?通常您需要更動/翻譯的部分位於header,也就是下方這一部分:
/* HEADER */
#header {
    height: 140px;
    position: relative;
    z-index: 10;
    padding-bottom: 30px; /* FOR MENU */
    background: url(http://scp-wiki.wdfiles.com/local--files/spc-001/SPCLogo50.png) 10px 35px no-repeat;
}
 
#header h1 a {
    content: "SPC Database";
}
 
#header h1 a::before {
    content: "SPC Database";
}
 
#header h1 a span{
    display: block;
    content: "";
    visibility: hidden;
}
 
#header h2 {
    margin-left: 120px;
    padding: 0;
    clear: left;
    float: left;
    font-size: 105%;
    max-height: 38px;
}
#header h2 span {
    display: block;
    margin: 0;
    padding: 19px 0;
    line-height: 0px;
    max-height: 0px;
    font-weight: bold;
    color: transparent;
    text-shadow: none;
}
#header h2 span::before {
    content: "Shark Punching Center";
    display: block;
    margin: 0;
    padding: 0px 0;
    line-height: 0px;
    max-height: 0px;
    font-weight: bold;
    color: #f0f0c0;
    text-shadow: 1px 1px 1px #000;
    text-shadow: 1px 1px 1px rgba(0,0,0,.8);
}


看到後請再做一件事:觀察原文頁面上的標題為何,這樣您才能確定需要更動/翻譯的地方為何。
我們可以得知:SPC Database以及Shark Punching Center是我們需要更動/翻譯的部分。下面為重點部位:
#header h1 a {
    content: "SPC Database";
}
 
#header h1 a::before {
    content: "SPC Database";
}

.
.
.
#header h2 span::before {
    content: "Shark Punching Center";
    display: block;
    margin: 0;
    padding: 0px 0;
    line-height: 0px;
    max-height: 0px;
    font-weight: bold;
    color: #f0f0c0;
    text-shadow: 1px 1px 1px #000;
    text-shadow: 1px 1px 1px rgba(0,0,0,.8);
}


我們應該要把SPC Database以及Shark Punching Center分別改成SPC資料庫以及毆打鯊魚中心,如下方所示:
#header h1 a {
    content: "SPC資料庫";
}
 
#header h1 a::before {
    content: "SPC資料庫";
}

.
.
.
#header h2 span::before {
    content: "毆打鯊魚中心";
    display: block;
    margin: 0;
    padding: 0px 0;
    line-height: 0px;
    max-height: 0px;
    font-weight: bold;
    color: #f0f0c0;
    text-shadow: 1px 1px 1px #000;
    text-shadow: 1px 1px 1px rgba(0,0,0,.8);
}


您翻完後注意到了嗎?每個需要更動/翻譯的文字皆位於名為"content"的宣告後面,且都被""框住,往後請改這裡就對了。但請注意!!,找到並更動文字後請再三確認""是否還留著,它很重要。
如果都完成的話頁面應該長這樣

[[include]]

基本上和[[module css]]一樣,但您必須繞個路,頁面源代碼裡頭開頭通常會有[[include 模板頁網址]],後方網址通常可直接被點擊,點擊後請參照[[module css]]部分進行更動/翻譯。

/code/1

當模板頁網址後有/code/1,請不要更動,僅需將前方網址以你的模板頁面網址覆蓋。

component:

翻譯時您會注意到編碼頁網址通常會有component:,這是宣告此頁面為一模板(或是部件)的編碼頁。創建一個新的頁面時請不要省略它。

提醒

  • 進行更動/翻譯時請在本站創建一個新的頁面。
  • 短時間內二次更動標題請稍待片刻,wikidot的更新速度並沒有非常快,它不會立即將更動內容套用在所有已連結的頁面上。

需要幫助?

請聯絡ChAoS_UnItYChAoS_UnItYminmasterqwminmasterqw或是WaterBrichWaterBrich,本站點專業技術人員群。

除非特別註明,本頁內容採用以下授權方式: Creative Commons Attribution-ShareAlike 3.0 License