@triptych/

Super Tiny IF Maker ( STIM )

HTML, CSS, JS

A very minimalist Interactive Fiction maker for the web.

fork
loading
Files
  • index.html
  • scripts
  • readme.md
  • style.css
index.html
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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
<!DOCTYPE html>
<html>

<head>
	<meta charset="utf-8">
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<title>Super Tiny IF Maker (STIM)</title>
	<!-- styles  -->
	<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/bulma/0.7.5/css/bulma.min.css" />

	<link href="style.css" rel="stylesheet" type="text/css" />

	<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.2.2/jszip.min.js">

	</script>
	<script defer src="https://use.fontawesome.com/releases/v5.3.1/js/all.js">

	</script>
	<script src="https://cdnjs.cloudflare.com/ajax/libs/cash/4.1.3/cash.min.js">

	</script>
	<script src="https://unpkg.com/torus-dom/dist/index.min.js">

	</script>
</head>

<body>
	<section class="section">
		<div class="container">
			<h1 class="title">
				<span class="icon"><i class="fas fa-book"></i></span>
        STIM
        </h1>
			<p class="subtitle stim-subtitle">
				Super Tiny Interactive fiction Maker

			</p>
		</div>
	</section>
  <!-- controls -->
	<section class="section">
		<div class="buttons has-addons stim-main-bar">
			<a class="button is-primary is-small" id="newstim" title="New STIM">
				<span class="icon">
          <i class="fas fa-plus-square"></i>
        </span>
        <span> New STIM</span>
      </a>

      <a class="button is-link is-small" title="Save STIM" id="savestim">
        <span class="icon">
          <i class="fas fa-save"></i>
        </span>
        <span>Save STIM</span>
      </a>

      <a class="button is-danger is-small" title="Load STIM" id="loadstim">
        <span class="icon">
          <i class="fas fa-truck-loading"></i>
        </span>
        <span>Load STIM</span>
      </a>
		</div>
    <div class="buttons has-addons">
      <a class="button is-small" id="importHTML">
        <span class="icon">
          <i class="fas fa-file-import"></i>
        </span>
        <span><input type="file" id="file" name="file"> <label for="file">Import</label> HTML</span>
      </a>

      <a class="button is-black is-small" id="exportHTML">
        <span class="icon">
          <i class="fas fa-file-export"></i>
        </span>
        <span>Export HTML</span>
      </a>
      
      
    </div>
    <di id="dlbutton"></div>
  </section>
<div class="buttons has-addons is-right stim-row">
  <span class="button" id="story-settings">
               <span class="icon clickable"  title="Story Settings" data-title="">
              <i class="fas fa-cog"></i>
              </span>
  </span>
  <span class="button" id="reorder">
            <span class="icon clickable" id="reorder" title="Reorder">
              <i class="fas fa-sort"></i>
              </span>

  </span>
  <span class="button" id="about-stim">
            <span class="icon clickable" title="About this project" >
          <i class="fas fa-info-circle"></i>
        </span>
  </span>
  <span class="button" id="reload">
            <span class="icon clickable"  title="Reload">
              <i class="fas fa-sync-alt"></i>
              </span>

  </span>
</div>

    <section class="section">
      <div class="columns is-mobile">
        <article class="column is-3-mobile">
          <!-- Add content or other tiles -->
          <h5 class="title is-5">Parts</h5>
          <p class="buttons">
            <!-- add text -->
            <a class="button" title="Add Paragraph" id='addParagraph'>
              <span class="icon is-small">
                <i class="fas fa-paragraph"></i>
              </span>
            </a>
            <!-- add choice -->
            <a class="button" title="Add Choice(s)" id="addChoice">
              <span class="icon is-small">
                <i class="fas fa-list"></i>    
              </span>
            </a>

            <!-- add image -->

            <a class="button" title="Add Image" disabled>
            <span class="icon is-small">
            <i class="fas fa-images"></i>
            </span>
            </a>

            <!-- add transition -->
            <a class="button" title="Add Transition" disabled>
              <span class="icon is-small">
                <i class="fas fa-adjust"></i>  
              </span>  
            </a>

            <!-- add video -->

            <a class="button" title="Add Video" disabled>
            <span class="icon is-small">
            <i class="fas fa-video"></i>
            </span>
            </a>

            <!-- add code -->
            
            <a class="button" title="Add Code" disabled>
            <span class="icon is-small">
            <i class="fas fa-code"></i>
            </span>
            </a>

          </p>
        </article>
        <article class="column" id="storyNode">
          <!-- Add content or other tiles -->
          <h5 class="title is-5">
            Story

 
            

            </h5>

          <!-- CARDS GO HERE -->
        
        </article>
      </div>
    </section>

<div id="modals"></div>

<!-- modal -->
<div class="modal" id="debugmodal">
  <div class="modal-background"></div>
  <div class="modal-content">
    <!-- Any other Bulma elements you want -->
    <div class="box"> 
      
    </div>
  </div>
  <button class="modal-close is-large" aria-label="close" id='debugmodalclose'></button>
</div>

<!-- settings -->

<div class="modal" id="settings-modal">
  <div class="modal-background"></div>
  <div class="modal-card">
    <header class="modal-card-head">
      <p class="modal-card-title">Game Settings</p>
      <button class="delete" aria-label="close"></button>
    </header>
    <section class="modal-card-body">
      <div><label for="game-title">Game Title</label> <input type="text" id="game-title"/></div>
    </section>
    <footer class="modal-card-foot">
      <button class="button is-success">Save changes</button>
      <button class="button btn-cancel">Cancel</button>
    </footer>
  </div>
</div>

<!-- reorder -->
<!-- move this to TORUS --> 
<!-- <div class="modal" id="reorder-modal">
  <div class="modal-background">></div>
  <div class="modal-card">
        <header class="modal-card-head">
          <p class="modal-card-title">Reorder Elements</p>
          <button class="delete" aria-label="close"></button>
        </header>
        <section class="modal-card-body">
          [ Content here]

        </section>
        <footer class="modal-card-foot">
          <button class="button is-success">Save changes</button>
          <button class="button btn-cancel">Cancel</button>
        </footer>
  </div>
</div> -->



<!-- templates -->
<template id="runtimeHTML">

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width">
    <title>STIM: Runtime demo</title>
    <script src="https://unpkg.com/torus-dom/dist/index.min.js">

	</script>
    <link href="style.css" rel="stylesheet" type="text/css" />
  </head>
  <body>
    <div id="game"></div>
    <script src="core.js" type="module"></script>
    <script src="stim.js"></script>
  </body>
</html>

</template>

<hr>
<div class="container">
  <div class="notification">
    Debug stuff below:
  </div>
  <div id="debug"></div>
  <hr>
  <button id="debug-showstate" class="button is-black">ShowState</button>

  <button id="debug-refresh" class="button is-warning">
    Refresh View</button>
</div>


    <script src="scripts/script.js" type="module"></script>
  </body>
</html>
result
console