yosup/web/index.html
2022-12-15 15:39:29 -08:00

182 lines
6.4 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Damus</title>
<link rel="stylesheet" href="css/vars.css?v=1">
<link rel="stylesheet" href="css/utils.css?v=1">
<link rel="stylesheet" href="css/styles.css?v=13">
<link rel="stylesheet" href="css/responsive.css?v=10">
<script defer src="js/util.js?v=5"></script>
<script defer src="js/ui/util.js?v=8"></script>
<script defer src="js/ui/render.js?v=15"></script>
<script defer src="js/ui/state.js?v=1"></script>
<script defer src="js/ui/fmt.js?v=1"></script>
<script defer src="js/noble-secp256k1.js?v=1"></script>
<script defer src="js/bech32.js?v=1"></script>
<script defer src="js/nostr.js?v=7"></script>
<script defer src="js/core.js?v=1"></script>
<script defer src="js/damus.js?v=92"></script>
</head>
<body>
<script>
// This is our main entry.
// https://developer.mozilla.org/en-US/docs/Web/API/Window/DOMContentLoaded_event
addEventListener('DOMContentLoaded', (ev) => {
damus_web_init();
});
</script>
<div id="gsticker" title="This is alpha software.">αlpha</div>
<nav id="gnav" class="">
<button class="icon" role="open-gnav" title="Open Menu" onclick="toggle_gnav(this)">
<img class="icon svg invert" src="icon/logo.svg"/>
</button>
<button class="icon" role="home" title="Home" onclick="switch_view('home')">
<img class="icon svg invert" src="icon/home.svg"/>
</button>
<button class="icon" role="explore" title="Explore" onclick="switch_view('explore')">
<img class="icon svg invert" src="icon/explore.svg"/>
</button>
<button class="icon" role="notifications" title="Notifications" onclick="switch_view('notifications')">
<img class="icon svg invert" src="icon/notifications.svg"/>
<div class="new-notifications hide"></div>
</button>
<button class="icon" role="sign-out" title="Sign Out" onclick="press_logout()">
<img class="icon svg invert" src="icon/sign-out.svg"/>
</button>
</nav>
<div id="container">
<div class="flex-fill vertical-hide"></div>
<div id="nav" class="flex-noshrink vertical-hide">
<div data-active="home">
<div id="app-icon-logo">
<img class="icon svg" title="Damus" src="icon/logo-inverted.svg"/>
</div>
<button role="home" class="nav icon"
title="Home" onclick="switch_view('home')">
<img class="icon svg inactive" src="icon/home.svg"/>
<img class="icon svg active" src="icon/home-active.svg"/>
</button>
<button role="explore" class="nav icon"
title="Explore" onclick="switch_view('explore')">
<img class="icon svg inactive" src="icon/explore.svg"/>
<img class="icon svg active" src="icon/explore-active.svg"/>
</button>
<button role="notifications" class="nav icon"
title="Notifications" onclick="switch_view('notifications')">
<img class="icon svg inactive" src="icon/notifications.svg"/>
<img class="icon svg active" src="icon/notifications-active.svg"/>
<div class="new-notifications hide"></div>
</button>
<button title="Sign Out" class="nav icon" onclick="press_logout()">
<img class="icon svg" src="icon/sign-out.svg"/>
</button>
</div>
</div>
<div id="view">
<div id="home-view">
<header>
<label>Home</label>
</header>
<div id="newpost">
<div class="my-userpic vertical-hide">
<!-- To be loaded dynamically. -->
</div>
<div>
<textarea placeholder="What's up?"
oninput="post_input_changed(this)"
class="post-input" id="post-input"></textarea>
<div class="post-tools">
<input id="content-warning-input" class="cw hide" type="text" placeholder="Reason"/>
<button title="Mark this message as sensitive."
onclick="toggle_cw(this)" class="cw icon">
<img class="icon svg small" src="icon/content-warning.svg"/>
</button>
<button onclick="send_post(this)" class="action"
role="send" id="post-button" disabled>Send</button>
</div>
</div>
</div>
<div class="events"></div>
</div>
<div id="explore-view" class="hide">
<header>
<label>Explore</label>
</header>
<div class="events"></div>
</div>
<div id="notifications-view" class="hide">
<header>
<label>Notifications</label>
</header>
<div class="events"></div>
</div>
<div id="thread-view" class="hide">
<header>
<label>Thread</label>
</header>
<div class="events"></div>
</div>
<div id="profile-view" class="hide">
<header>
<label role="profile-name">Profile</label>
</header>
<div role="profile-info" class="bottom-border">
<div class="flex">
<img role="profile-image" class="pfp jumbo" src="" />
<div class="profile-tools">
<!--
<button class="icon" title="Message User" role="message-user">
<img class="icon" src="icon/message-user.svg"/></button>
-->
<button class="icon" role="copy-pk"
data-pk="" onclick="click_copy_pk(this)" title="Copy Public Key">
<img class="icon svg" src="icon/pubkey.svg"/></button>
<button class="action" role="follow-user" data-pk=""
onclick="click_toggle_follow_user(this)">Follow</button>
</div>
</div>
<div>
<label role="profile-nip5"></label>
<p role="profile-desc"></p>
</div>
</div>
<div class="events"></div>
</div>
</div>
<div class="flex-fill vertical-hide"></div>
</div>
<div class="modal closed" id="media-preview">
<div class="bg-blur"></div>
<div class="media-container">
<img onclick="close_media_preview()" src=""/>
</div>
<!-- TODO add loader to media preview -->
</div>
<div class="modal closed" id="reply-modal">
<div id="reply-modal-content" class="modal-content">
<header>
<label>Reply To</label>
<button class="icon" onclick="close_reply()">
<img class="icon svg" src="icon/close-modal.svg"/>
</button>
</header>
<div id="replying-to"></div>
<div id="replybox">
<textarea id="reply-content" class="post-input" oninput="post_input_changed(this)"
placeholder="Write your reply here..."></textarea>
<div class="post-tools">
<button id="reply-button" class="action" onclick="do_send_reply()">
Reply
</button>
</div>
</div>
</div>
</div>
</body>
</html>