Skip to content

Commit d4a0202

Browse files
authored
Merge pull request #1 from Federico-G/fede
Debuggear code alpha 1
2 parents dc72165 + a08c11c commit d4a0202

30 files changed

+3193
-736
lines changed

README.md

+36-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,36 @@
1-
# debuggear
1+
# debuggear
2+
3+
Debuggear es una aplicación para ayudar a aquellas personas que estan entrando en el espectacular mundo de la programación y la algoritmia. Esta aplicación permite capturar un algoritmo generado a mano, interpretarlo, y permitir ejecutarlo paso a paso
4+
5+
6+
{acerca de}
7+
8+
9+
10+
11+
## Consultas y reporte de errores
12+
{issues de github}
13+
14+
15+
16+
## Tecnologias usadas:
17+
- Hosteado en Firebase
18+
- Tensorflowjs: Reconocimiento de formas (local)
19+
- Google Cloud Vision Handwriting OCR: Reconocimiento de texto (via nodejs)
20+
- Interactjs: Manipulación de formas en la aplicación
21+
- Nearleyjs: Interpretación de los lenguajes en BNF, y su validación
22+
- Rextester: Ejecución de cada paso sobre el lenguaje aplicado
23+
- Jquery v3
24+
- Bootstrap v4 para el diseño del frontend
25+
- Compressorjs para la compresión de imagenes subidas por el usuario
26+
- Basado en estandares de PWA para funcionar también como aplicación movil
27+
28+
29+
## Lenguajes soportados
30+
Aunque la aplicación se pensó para soportar varios lenguajes, por ahora sólo soporta C (C99)
31+
32+
33+
## Próximos pasos
34+
- Mejorar forma de compartir (Ya que reconocer extensiones de archivos para la aplicación como PWA esta ["demorado"](https://github.com/w3c/manifest/issues/626)
35+
- Migrar a Bootstrap v5 y quitar Jquery
36+
- Agregar Arreglos

package-lock.json

+51
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/css/bootstrap.min.css

-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/css/main.css

+43-14
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
:root {
22
--main-color: #F3841B;
33
--secondary-color: #AC4A87;
4+
--font-size: 20px; /* define */
45
}
56

67
html {
@@ -13,16 +14,17 @@ body {
1314
flex-direction: column;
1415
}
1516

16-
nav.navbar {
17+
.main-color {
1718
background-color: var(--main-color);
1819
}
1920

20-
nav.navbar .navbar-brand {
21-
color: #FFFFFF;
21+
.sql-color {
22+
background-color: var(--secondary-color);
2223
}
2324

24-
nav.navbar .navbar-brand:hover {
25-
color: #FFFFFF;
25+
#version {
26+
font-size: 10px;
27+
color: #DCB;
2628
}
2729

2830
main {
@@ -35,7 +37,6 @@ footer {
3537
display: flex;
3638
justify-content: space-evenly;
3739
flex-direction: row;
38-
background: var(--main-color);
3940
text-align: center;
4041
}
4142

@@ -50,6 +51,10 @@ footer > * {
5051
padding-bottom: 8px;
5152
}
5253

54+
footer > .disabled, footer > :disabled {
55+
color: #777;
56+
}
57+
5358
footer a:hover {
5459
color: #FFF;
5560
text-decoration: none;
@@ -63,11 +68,12 @@ footer a:hover {
6368
font-size: 28px;
6469
position: absolute;
6570
padding: 25px;
66-
height: 100%;
71+
/*height: 100%;*/
6772
width: 100%;
6873
display: flex;
6974
flex-direction: column;
70-
place-content: center;
75+
/*place-content: center*/;
76+
z-index: 1;
7177
}
7278

7379
#diagram-bg-image > img {
@@ -120,17 +126,19 @@ footer a:hover {
120126
outline: 0;
121127
position: absolute;
122128
width: 100%;
123-
height: 30px;
129+
/*height: var(--font-size)*X;*/
130+
height: 100%;
124131
text-align: center;
125132
resize: none;
126133
overflow: hidden;
134+
font-family: monospace;
127135
}
128136

129137
#add_shape {
130138
position: absolute;
131139
right: 25px;
132140
bottom: 105px;
133-
z-index: 2000;
141+
z-index: 1001;
134142
}
135143

136144
#add_shape > button {
@@ -146,7 +154,7 @@ footer a:hover {
146154
position: absolute;
147155
left: 25px;
148156
bottom: 105px;
149-
z-index: 2000;
157+
z-index: 1001;
150158
border-radius: 60px;
151159
width: 60px;
152160
height: 60px;
@@ -173,11 +181,21 @@ footer a:hover {
173181
position: absolute;
174182

175183
z-index: 100;
184+
185+
font-family: monospace;
186+
font-size: var(--font-size);
176187
}
177188

178189
#shape-container {
190+
transform-origin: 0 0;
179191
position: relative;
180192
height: 5000px;
193+
width: 1000px;
194+
}
195+
196+
.shape-end {
197+
padding-top: 0;
198+
padding-bottom: 15px;
181199
}
182200

183201
.shape-while {
@@ -187,7 +205,7 @@ footer a:hover {
187205

188206
.shape-if {
189207
align-items: flex-start;
190-
padding-top: 50px;
208+
padding-top: 90px;
191209
z-index: 90;
192210
}
193211

@@ -206,16 +224,27 @@ footer a:hover {
206224
height: 70px;
207225
}
208226

227+
.popover {
228+
font-size: 3vw;
229+
}
230+
231+
.popover:hover {
232+
z-index: 2000;
233+
}
234+
209235

210236

211237

212238
/* RUN */
213239
#console-container {
214-
max-height: 100px;
240+
max-height: 150px;
215241
overflow-y: auto;
242+
font-size: 17px;
243+
font-family: monospace;
244+
white-space: pre-wrap;
216245
}
217246
#console-container > div {
218-
min-height: 100px;
247+
min-height: 150px;
219248
/*background-color: rgba(255, 255, 255, 0.9375);*/
220249
background: #FAFAFA;
221250
}

public/index.html

+53-14
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
<meta name='viewport' content='width=device-width, initial-scale=1' />
77
<link rel='shortcut icon' href='favicon.ico' />
88
<title>Debuggear web</title>
9+
<meta name="title" content="Debuggear web">
10+
<meta name="description" content="Description">
911

1012
<link rel="manifest" href="/manifest.json" />
1113

@@ -20,6 +22,13 @@
2022
<meta name="msapplication-TileColor" content="#FFFFFF">
2123
<meta name="theme-color" content="#F3841B">
2224

25+
<!-- Open Graph -->
26+
<meta property="og:type" content="website">
27+
<meta property="og:url" content="https://debuggear-web.web.app/">
28+
<meta property="og:title" content="Debuggear web">
29+
<meta property="og:description" content="Description">
30+
<meta property="og:image" content="https://debuggear-web.web.app/android-chrome-512x512.png">
31+
2332
<!-- vendor -->
2433
<link type='text/css' rel='stylesheet' href='css/font-awesome.min.css' />
2534
<link type='text/css' rel='stylesheet' href='css/bootstrap.min.css' />
@@ -28,24 +37,50 @@
2837
<link type='text/css' rel='stylesheet' href='css/main.css' />
2938
</head>
3039
<body>
31-
<header role="banner">
32-
<nav class="navbar navbar-expand-lg navbar-light">
40+
<header role="banner" style="z-index: 1002;">
41+
<nav class="navbar navbar-expand-lg navbar-dark main-color">
3342
<div class="container">
3443
<span class="navbar-brand">
3544
<img src="/image/white-icon.svg" width="32" />
3645
Debuggear
3746
</span>
47+
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
48+
<span class="navbar-toggler-icon"></span>
49+
</button>
50+
<div class="collapse navbar-collapse" id="navbarSupportedContent">
51+
<ul class="navbar-nav">
52+
<li class="nav-item">
53+
<a class="nav-link" href="#" onclick="dg.step.screenMain(); $('.navbar-collapse').collapse('hide'); return false;">Diagrama</a>
54+
</li>
55+
<li class="nav-item">
56+
<a class="nav-link" href="#" onclick="dg.step.screenInfo(); $('.navbar-collapse').collapse('hide'); return false;">Info</a>
57+
</li>
58+
<li class="nav-item">
59+
<a class="nav-link" href="#" onclick="dg.step.screenHelp(); $('.navbar-collapse').collapse('hide'); return false;">Ayuda</a>
60+
</li>
61+
<li class="nav-item">
62+
<a class="nav-link" href="#" onclick="dg.step.screenFunctions(); $('.navbar-collapse').collapse('hide'); return false;">Funciones</a>
63+
</li>
64+
<li class="nav-item" style="display: none;">
65+
<a class="nav-link" href="#" id="instalar"><i class='fa fa-mobile'></i> <span>Instalar</span></a>
66+
</li>
67+
<li class="nav-item">
68+
<a class="nav-link disabled" href="#"><span id="version"></span></a>
69+
</li>
70+
</ul>
71+
</div>
3872
</div>
3973
</nav>
4074
</header>
75+
4176
<main id='main' role='main'>
4277
<div id='intro' style="position: absolute;"></div>
4378
<div id='diagram-bg-image'></div>
4479
<div id='shape-container'></div>
4580
</main>
4681
<div id='buttons'></div>
4782
<div id='console-container'></div>
48-
<footer></footer>
83+
<footer class="main-color"></footer>
4984
<div class="modal fade" id="symbol-table" tabindex="-1" aria-labelledby="symbol-table-label" aria-hidden="true">
5085
<div class="modal-dialog">
5186
<div class="modal-content">
@@ -60,12 +95,17 @@ <h5 class="modal-title" id="symbol-table-label">Tabla de símbolos</h5>
6095
</div>
6196
</div>
6297

98+
<!-- Google ads -->
99+
<script data-ad-client="ca-pub-1993499454382682" async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
100+
63101
<!-- vendor -->
64102
<script src='js/jquery.min.js'></script>
65103
<script src='js/bootstrap.bundle.min.js'></script>
66104
<script src='js/interact.min.js'></script>
67105
<script src='js/compressor.min.js'></script>
68106

107+
<script src='js/nearley.js'></script>
108+
69109
<script src='js/tf.min.js'></script>
70110
<script src='js/tf-automl.min.js'></script>
71111

@@ -76,18 +116,17 @@ <h5 class="modal-title" id="symbol-table-label">Tabla de símbolos</h5>
76116
<script src='js/menu.js'></script>
77117
<script src='js/step.js'></script>
78118
<script src='tf.js'></script>
79-
<script src='js/code/code.js'></script>
80119

81-
<script type="text/javascript">
82-
if ('serviceWorker' in navigator) {
83-
window.addEventListener('load', function() {
84-
navigator.serviceWorker.register('/sw.js');
85-
});
86-
}
120+
<script src='js/code/Console.js'></script>
121+
<script src='js/code/Node.js'></script>
122+
<script src='js/code/Step.js'></script>
123+
<script src='js/code/Symbol.js'></script>
124+
<script src='js/code/SymbolTable.js'></script>
125+
<script src='js/code/Tree.js'></script>
87126

88-
$(function() {
89-
dg.step.check();
90-
});
91-
</script>
127+
<script src='js/language/c/bnf.js'></script>
128+
<script src='js/language/c/validation.js'></script>
129+
<script src='js/language/c/solver.js'></script>
130+
<script src='js/language/c/to-code.js'></script>
92131
</body>
93132
</html>

public/js/bootstrap.bundle.min.js

-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)