summaryrefslogtreecommitdiff
path: root/app/views/dashboard/show.html.tmpl
blob: e17f2175c2f47b19495661512284397086c94eeb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
<!doctype html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="color-scheme" content="light dark">
    <title>SparkleLab</title>
    <link rel="stylesheet" href="/pico.min.css">
    <script src="/htmx.js"></script>
    <script src="/vue.global.js"></script>
    <script src="/application.js"></script>
  </head>
  <body>
    <header class="container" hx-get="/dashboard/nav" hx-trigger="load">
      <progress />
    </header>

    <main id="app" class="container">
      <div class="grid">
        <div>&nbsp;</div>
        <div>
          <hgroup>
            <h2>Share your gratitude</h2>
            <p>Sparkle someone with praise</p>
          </hgroup>
        </div>
        <div>&nbsp;</div>
      </div>

      <form v-on:submit.prevent="submitSparkle">
        <label>/sparkle <input type="text" placeholder="@tanuki for helping me with my homework!" v-model="sparkle" pattern="\s*(?<sparklee>@\w+)\s+(?<reason>.+)" required /> </label>
        <button type="submit" v-bind:disabled="isDisabled">✨ Sparkle</button>
      </form>
      <span class="error">${ errorMessage }</span>

      <h1>${ heading }</h1>
      <article v-for="sparkle in recentSparkles">
        <header>
          <img :src="sparkle.author.picture" :alt="sparkle.author.username">
          <a :href="sparkle.author.profile"><strong>@${ sparkle.author.username }</strong></a> says
        </header>
        <blockquote>
          /sparkle <strong>${ sparkle.sparklee }</strong> ${ sparkle.reason }
        </blockquote>
      </article>
    </main>
  </body>

  <footer>
    <div class="container">
      <div class="grid">
        <div>
            <p> <strong>Why?</strong> </p>
            <p> <small> SparkleLab is a lightweight service designed to explore modern access control models within GitLab, while doing something fun: helping GitLab team members show appreciation for each other. </small> </p>
            <p> <small> Built with ❤ by the <a href="https://handbook.gitlab.com/handbook/engineering/development/sec/software-supply-chain-security/authorization/" class="secondary">authz team</a> at GitLab. </small> </p>
        </div>
        <aside>
          <nav>
            <ul>
              <li> <strong>About</strong> </li>
              <li><a href="https://handbook.gitlab.com/handbook/communication/#say-thanks" class="secondary">Say Thanks</a></li>
              <li><a href="https://gitlab.enterprise.slack.com/archives/C038E3Q6L" class="secondary">#thanks</a></li>
            </ul>
          </nav>
        </aside>
        <aside>
          <nav>
            <ul>
              <li><strong>Contribute</strong></li>
              <li><a href="https://gitlab.com/gitlab-org/software-supply-chain-security/authorization/sparkled" class="secondary">Code</a></li>
              <li><a href="https://gitlab.com/gitlab-org/software-supply-chain-security/authorization/sparkled/-/issues " class="secondary">Issues</a></li>
            </ul>
          </nav>
        </aside>
      </div>
    </div>
  </footer>
</html>