-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
115 lines (108 loc) · 3.92 KB
/
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Rich Text Editor</title>
<!-- FontAwesome Icons -->
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.1.1/css/all.min.css"
/>
<!-- Google Fonts -->
<link
href="https://fonts.googleapis.com/css2?family=Poppins&display=swap"
rel="stylesheet"
/>
<!-- Stylesheet -->
<link rel="stylesheet" href="style.css" />
</head>
<body>
<div class="container">
<div class="options">
<!-- Text Format -->
<button id="bold" class="option-button format">
<i class="fa-solid fa-bold"></i>
</button>
<button id="italic" class="option-button format">
<i class="fa-solid fa-italic"></i>
</button>
<button id="underline" class="option-button format">
<i class="fa-solid fa-underline"></i>
</button>
<button id="strikethrough" class="option-button format">
<i class="fa-solid fa-strikethrough"></i>
</button>
<button id="superscript" class="option-button script">
<i class="fa-solid fa-superscript"></i>
</button>
<button id="subscript" class="option-button script">
<i class="fa-solid fa-subscript"></i>
</button>
<!-- List -->
<button id="insertOrderedList" class="option-button">
<div class="fa-solid fa-list-ol"></div>
</button>
<button id="insertUnorderedList" class="option-button">
<i class="fa-solid fa-list"></i>
</button>
<!-- Undo/Redo -->
<button id="undo" class="option-button">
<i class="fa-solid fa-rotate-left"></i>
</button>
<button id="redo" class="option-button">
<i class="fa-solid fa-rotate-right"></i>
</button>
<!-- Link -->
<button id="createLink" class="adv-option-button">
<i class="fa fa-link"></i>
</button>
<button id="unlink" class="option-button">
<i class="fa fa-unlink"></i>
</button>
<!-- Alignment -->
<button id="justifyLeft" class="option-button align">
<i class="fa-solid fa-align-left"></i>
</button>
<button id="justifyCenter" class="option-button align">
<i class="fa-solid fa-align-center"></i>
</button>
<button id="justifyRight" class="option-button align">
<i class="fa-solid fa-align-right"></i>
</button>
<button id="justifyFull" class="option-button align">
<i class="fa-solid fa-align-justify"></i>
</button>
<button id="indent" class="option-button spacing">
<i class="fa-solid fa-indent"></i>
</button>
<button id="outdent" class="option-button spacing">
<i class="fa-solid fa-outdent"></i>
</button>
<!-- Headings -->
<select id="formatBlock" class="adv-option-button">
<option value="H1">H1</option>
<option value="H2">H2</option>
<option value="H3">H3</option>
<option value="H4">H4</option>
<option value="H5">H5</option>
<option value="H6">H6</option>
</select>
<!-- Font -->
<select id="fontName" class="adv-option-button"></select>
<select id="fontSize" class="adv-option-button"></select>
<!-- Color -->
<div class="input-wrapper">
<input type="color" id="foreColor" class="adv-option-button" />
<label for="foreColor">Font Color</label>
</div>
<div class="input-wrapper">
<input type="color" id="backColor" class="adv-option-button" />
<label for="backColor">Highlight Color</label>
</div>
</div>
<div id="text-input" contenteditable="true"></div>
</div>
<!--Script-->
<script src="script.js"></script>
</body>
</html>