跳转到内容
打开/关闭菜单
  • 451 条目
  • 808 文件
  • 22 用户
  • 9241 编辑
Blockland Wiki
打开/关闭外观设置菜单
打开/关闭个人菜单
未登录
未登录用户的IP地址会在进行任意编辑后公开展示。

模板:Infobox country:修订间差异

来自Blockland Wiki
无编辑摘要
无编辑摘要
第25行: 第25行:
| abovestyle = background-color:#CCEEFF; padding:0.5em; text-align:center; border-bottom:1px solid #a2a9b1;
| abovestyle = background-color:#CCEEFF; padding:0.5em; text-align:center; border-bottom:1px solid #a2a9b1;
| aboveclass = fn org
| aboveclass = fn org
| above = <div style="font-size:1.25em; font-weight:bold;">{{{国名全称|}}}</div><div style="font-size:1.1em; font-weight:bold;">{{{国名|{{PAGENAME}}}}}</div><div style="font-size:0.9em; font-weight:normal; margin-top:0.2em; line-height:1.3em;">{{#if:{{{格言|}}}|<div style="font-style:italic;">'''格言''':“{{{格言}}}”</div>}}{{#if:{{{国歌|}}}|<div style="margin-top:0.1em;">'''国歌''':《{{{国歌}}}》</div>}}</div>
| above = <div style="font-size:1.25em; font-weight:bold;">{{{国名全称|}}}</div><div style="font-size:1.1em; font-weight:bold;">{{{国名|{{PAGENAME}}}}}</div><div style="font-size:0.9em; font-weight:normal; margin-top:0.2em; line-height:1.3em;">{{#if:{{{格言|}}}|<div style="font-style:italic;">“{{{格言}}}”</div>}}{{#if:{{{国歌|}}}|<div style="margin-top:0.1em;">《{{{国歌}}}》</div>}}</div>


| headerstyle = background-color:#f0f0f0; font-weight:bold; text-align:center; padding:4px; border-top:1px solid #a2a9b1; border-bottom:1px solid #a2a9b1;
| headerstyle = background-color:#f0f0f0; font-weight:bold; text-align:center; padding:4px; border-top:1px solid #a2a9b1; border-bottom:1px solid #a2a9b1;
第65行: 第65行:
| data32 = {{{历史事件2日期|}}}
| data32 = {{{历史事件2日期|}}}


| header35 = 地图标注
| header35 = {{#if:{{{纬度|}}}{{{经度|}}}|地理位置|{{#if:{{{地图图片|}}}|地图}}}}
| data36 = {{#if:{{{纬度|}}}{{{经度|}}}|
| data36 = {{#if:{{{纬度|}}}{{{经度|}}}|
<div id="country-map-{{{国名|{{PAGENAME}}}}}" style="width:100%; height:200px; background:#ddd; border:1px solid #ccc; margin:5px 0;"></div>
{{#tag:html|
<link rel="stylesheet" href="https://unpkg.com/[email protected]/dist/leaflet.css" />
<link rel="stylesheet" href="https://unpkg.com/[email protected]/dist/leaflet.css" />
<style>
  .leaflet-container { background: #f8f9fa !important; }
</style>
<div id="map-ctx-{{#time:U}}" style="width:100%; height:200px; border:1px solid #a2a9b1; margin:5px 0;"></div>
<script src="https://unpkg.com/[email protected]/dist/leaflet.js"></script>
<script src="https://unpkg.com/[email protected]/dist/leaflet.js"></script>
<script>
<script>
第75行: 第79行:
     var lng = parseFloat("{{{经度|0}}}");
     var lng = parseFloat("{{{经度|0}}}");
     var zoom = parseInt("{{{缩放|4}}}");
     var zoom = parseInt("{{{缩放|4}}}");
     var tiles = "http://blkl.fun//wp-content/uploads/arcgis_tiles/_alllayers0408";
     var tiles = "http://blkl.fun/wp-content/uploads/arcgis_tiles/_alllayers0408";
      
      
     var map = L.map("country-map-{{{国名|{{PAGENAME}}}}}" , {
     var mapId = "map-ctx-{{#time:U}}";
         zoomControl: false,
    var map = L.map(mapId, {
         zoomControl: true,
         attributionControl: false,
         attributionControl: false,
         maxZoom: 9,
         maxZoom: 9,
第84行: 第89行:
     }).setView([lat, lng], zoom);
     }).setView([lat, lng], zoom);


     L.TileLayer.ArcGISLocal = L.TileLayer.extend({
     var ArcGISLayer = L.TileLayer.extend({
         getTileUrl: function(coords) {
         getTileUrl: function(coords) {
             var z = coords.z;
             var z = coords.z;
             var x = coords.x;
             var x = coords.x;
             var y = coords.y;
             var y = coords.y;
            // 补零逻辑适配你提供的 ArcGIS 路径格式
             var sz = z.toString().padStart(2, '0');
             var sz = z.toString().padStart(2, '0');
             var sy = y.toString(16).padStart(8, '0');
             var sy = y.toString(16).padStart(8, '0');
第97行: 第101行:
     });
     });


     new L.TileLayer.ArcGISLocal().addTo(map);
     new ArcGISLayer().addTo(map);
    L.marker([lat, lng]).addTo(map);
      
      
     var icon = L.divIcon({
     // 延迟修正容器大小
        html: '<div style="color:#ff3b30;"><span style="font-size:24px;">📍</span></div>',
     setTimeout(function(){ map.invalidateSize(); }, 500);
        className: '',
        iconSize: [24, 24],
        iconAnchor: [12, 24]
     });
    L.marker([lat, lng], {icon: icon}).addTo(map);
})();
})();
</script>
</script>
}}
| {{#if:{{{地图图片|}}}|[[File:{{{地图图片}}}|250px]]<br/><small>{{{地图说明|}}}</small>}} }}
| {{#if:{{{地图图片|}}}|[[File:{{{地图图片}}}|250px]]<br/><small>{{{地图说明|}}}</small>}} }}



2026年5月10日 (日) 12:28的版本

此模板定义表格“Countries”。 查看表格.