132 lines
6.9 KiB
HTML
132 lines
6.9 KiB
HTML
<!doctype html>
|
||
<html lang="en">
|
||
<head>
|
||
<meta charset="utf-8">
|
||
<title>Export</title>
|
||
<script src="./support.js"></script>
|
||
</head>
|
||
<body>
|
||
<x-dc>
|
||
<helmet>
|
||
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Barlow:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500&display=swap">
|
||
<style>
|
||
body{margin:0}
|
||
a{color:#F5B544}a:hover{color:#FFD07A}
|
||
</style>
|
||
</helmet>
|
||
<div style="width: 390px; height: 844px; box-sizing: border-box; position: relative; overflow: hidden; background: #0A0D13; color: #E8ECF2; font-family: 'Barlow', system-ui, sans-serif; padding: 56px 20px 0">
|
||
<div style="display: flex; align-items: center; gap: 8px">
|
||
<a href="Review.dc.html" aria-label="Back to review" style="width: 44px; height: 44px; margin-left: -10px; display: flex; align-items: center; justify-content: center; color: #E8ECF2">
|
||
<svg width="22" height="22" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M15 5l-7 7 7 7"></path></svg>
|
||
</a>
|
||
<div style="display: flex; flex-direction: column; gap: 2px; flex: 1">
|
||
<h1 style="margin: 0; font-size: 22px; font-weight: 700">Export</h1>
|
||
<span style="font-size: 13px; color: #93A0B4">Backyard pier · margin +2.0° · north offset 0.0°</span>
|
||
</div>
|
||
</div>
|
||
|
||
<div style="margin-top: 16px; display: flex; flex-direction: column; gap: 8px">
|
||
<sc-for list="{{formats}}" as="f" hint-placeholder-count="3">
|
||
<label style="{{f.card}}">
|
||
<input type="checkbox" checked="{{f.on}}" onChange="{{f.toggle}}" style="width: 22px; height: 22px; margin: 2px 0 0; accent-color: #F5B544; flex: none">
|
||
<span style="display: flex; flex-direction: column; gap: 3px; min-width: 0">
|
||
<span style="display: flex; align-items: center; gap: 8px">
|
||
<span style="font-size: 16px; font-weight: 600">{{f.title}}</span>
|
||
<span style="font-family: 'IBM Plex Mono', ui-monospace, monospace; font-size: 11px; padding: 2px 6px; border-radius: 6px; background: #1A2130; color: #C9D2DE">{{f.ext}}</span>
|
||
</span>
|
||
<span style="font-size: 13px; line-height: 1.35; color: #93A0B4">{{f.sub}}</span>
|
||
</span>
|
||
</label>
|
||
</sc-for>
|
||
</div>
|
||
|
||
<div style="margin-top: 18px; display: flex; align-items: center; justify-content: space-between; gap: 8px">
|
||
<span style="font-family: 'IBM Plex Mono', ui-monospace, monospace; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: #93A0B4">Preview</span>
|
||
<div style="display: flex; gap: 4px; padding: 3px; border-radius: 10px; background: #121722; border: 1px solid #232C3B">
|
||
<button onClick="{{showHrz}}" style="{{hrzTab}}">.hrz</button>
|
||
<button onClick="{{showIni}}" style="{{iniTab}}">landscape.ini</button>
|
||
</div>
|
||
</div>
|
||
|
||
<div style="margin-top: 8px; height: 196px; box-sizing: border-box; overflow: hidden; border-radius: 14px; background: #06080C; border: 1px solid #1A2130; padding: 12px 14px; font-family: 'IBM Plex Mono', ui-monospace, monospace; font-size: 12px; line-height: 1.55; color: #C9D2DE">
|
||
<sc-if value="{{isIni}}" hint-placeholder-val="{{ true }}">
|
||
<div style="white-space: pre">[landscape]
|
||
name = Backyard pier
|
||
type = spherical
|
||
maptex = panorama.png
|
||
maptex_top = 42
|
||
maptex_bottom = -22
|
||
angle_rotatez = 0
|
||
bottom_cap_color = .05,.05,.05
|
||
|
||
[location]
|
||
latitude = +47d29'52"
|
||
longitude = +19d2'25"</div>
|
||
</sc-if>
|
||
<sc-if value="{{isHrz}}" hint-placeholder-val="{{ false }}">
|
||
<div style="white-space: pre">0 14.0
|
||
1 14.2
|
||
2 14.4
|
||
3 14.6
|
||
4 14.8
|
||
5 15.0
|
||
⋮
|
||
359 14.1</div>
|
||
<div style="margin-top: 4px; color: #7F8CA1">360 lines · azimuth altitude, +2° margin</div>
|
||
</sc-if>
|
||
</div>
|
||
|
||
<p style="margin: 12px 0 0; font-size: 13px; line-height: 1.4; color: #93A0B4; text-wrap: pretty">NINA: Options › General › Astrometry › Custom Horizon. Stellarium: install the .zip under Sky and viewing options › Landscape › Add/remove landscapes.</p>
|
||
|
||
<div style="position: absolute; left: 20px; right: 20px; bottom: 34px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px">
|
||
<button style="height: 56px; border-radius: 16px; border: 1px solid #263042; background: #121722; color: #E8ECF2; font-family: inherit; font-size: 16px; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 8px">
|
||
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M12 4v12M7 11l5 5 5-5M5 20h14"></path></svg>
|
||
Save
|
||
</button>
|
||
<button style="height: 56px; border-radius: 16px; border: none; background: #F5B544; color: #1A1204; font-family: inherit; font-size: 16px; font-weight: 700; display: flex; align-items: center; justify-content: center; gap: 8px">
|
||
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M12 3v12M7 8l5-5 5 5M5 14v5a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-5"></path></svg>
|
||
Share {{count}} files
|
||
</button>
|
||
</div>
|
||
</div>
|
||
</x-dc>
|
||
<script type="text/x-dc" data-dc-script data-props='{"$preview":{"width":390,"height":844}}'>
|
||
class Component extends DCLogic {
|
||
constructor(props) {
|
||
super(props);
|
||
this.state = { nina: true, pano: true, poly: false, tab: 'hrz' };
|
||
}
|
||
renderVals() {
|
||
const defs = [
|
||
{ id: 'nina', title: 'NINA custom horizon', ext: '.hrz', sub: 'Sky edge + safety margin as azimuth / altitude pairs, for target altitude limits' },
|
||
{ id: 'pano', title: 'Stellarium panorama', ext: '.zip', sub: 'Spherical landscape: 360° photo band with transparent sky, 8192 × 2048 PNG' },
|
||
{ id: 'poly', title: 'Stellarium outline only', ext: '.zip', sub: 'Polygonal landscape: just the horizon line, no photo' }
|
||
];
|
||
const formats = defs.map((d) => {
|
||
const on = !!this.state[d.id];
|
||
return {
|
||
...d,
|
||
on: on,
|
||
toggle: () => this.setState({ [d.id]: !this.state[d.id] }),
|
||
card: 'display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 14px; cursor: pointer; background: ' + (on ? '#1A2130' : '#121722') + '; border: 1px solid ' + (on ? '#F5B544' : '#232C3B')
|
||
};
|
||
});
|
||
const count = defs.filter((d) => this.state[d.id]).length;
|
||
const tab = (on) => 'height: 32px; padding: 0 10px; border-radius: 8px; border: none; font-family: IBM Plex Mono, ui-monospace, monospace; font-size: 12px; background: ' + (on ? '#E8ECF2' : 'transparent') + '; color: ' + (on ? '#0A0D13' : '#C9D2DE');
|
||
const isIni = this.state.tab === 'ini';
|
||
return {
|
||
formats: formats,
|
||
count: count,
|
||
isIni: isIni,
|
||
isHrz: !isIni,
|
||
iniTab: tab(isIni),
|
||
hrzTab: tab(!isIni),
|
||
showIni: () => this.setState({ tab: 'ini' }),
|
||
showHrz: () => this.setState({ tab: 'hrz' })
|
||
};
|
||
}
|
||
}
|
||
</script>
|
||
</body>
|
||
</html>
|