-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
121 lines (114 loc) · 8.46 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
116
117
118
119
120
121
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
<title>Resize Iframe</title>
<style>
.target {
padding: 50px 0;
}
</style>
</head>
<body>
<div class="target">
<input type="text">
<button onclick="sendPostMessageResize()">Set height</button>
</div>
<h1>Test text</h1>
<h4><span class="mw-headline" id="Visual_editing">Visual editing</span></h4>
<p>Wikis can also make <a href="/wiki/WYSIWYG" title="WYSIWYG">WYSIWYG</a> editing available to users, usually by
means of JavaScript control that translates graphically entered formatting instructions into the corresponding <a
href="/wiki/HTML_element" title="HTML element">HTML tags</a> or wikitext. In those implementations, the markup of
a newly edited, marked-up version of the page is generated and submitted to the server <a
href="/wiki/Transparency_(human-computer_interaction)" class="mw-redirect"
title="Transparency (human-computer interaction)">transparently</a>, shielding the user from this technical
detail. An example of this is the <a href="/wiki/VisualEditor" title="VisualEditor">VisualEditor</a> on Wikipedia.
WYSIWYG controls do not, however, always provide all of the features available in wikitext, and some users prefer
not to use a WYSIWYG editor. Hence, many of these sites offer some means to edit the wikitext directly.
</p>
<h4><span class="mw-headline" id="Version_history">Version history</span></h4>
<p>Some wikis keep a record of changes made to wiki pages; often, every version of the page is stored. This means that
authors can revert to an older version of the page should it be necessary because a mistake has been made, such as
the content accidentally being deleted or the page has been vandalized to include offensive or malicious text or
other inappropriate content.
</p>
<h4><span class="mw-headline" id="Edit_summary">Edit summary</span></h4>
<p>Many wiki implementations, such as <a href="/wiki/MediaWiki" title="MediaWiki">MediaWiki</a>, the software that
powers <a href="/wiki/Wikipedia" title="Wikipedia">Wikipedia</a>, allow users to supply an <i>edit summary</i> when
they edit a page. This is a short piece of text summarizing the changes they have made (e.g., "Corrected grammar,"
or "Fixed formatting in table."). It is not inserted into the article's main text, but is stored along with that
revision of the page, allowing users to explain what has been done and why, similar to a log message when making
changes in a <a href="/wiki/Revision_control" class="mw-redirect" title="Revision control">revision-control</a>
system. This enables other users to see which changes have been made by whom and why, often in a list of summaries,
dates and other short, relevant content, a list which is called a "log" or "history."
</p>
<h3><span class="mw-headline" id="Navigation_2">Navigation</span></h3>
<p>Within the text of most pages, there are usually many <a href="/wiki/Hypertext" title="Hypertext">hypertext</a>
links to other pages within the wiki. This form of non-linear navigation is more "native" to a wiki than
structured/formalized navigation schemes. Users can also create any number of index or table-of-contents pages, with
hierarchical categorization or whatever form of organization they like. These may be challenging to maintain "by
hand", as multiple authors and users may create and delete pages in an <a href="/wiki/Ad_hoc" title="Ad hoc">ad
hoc</a>, unorganized manner. Wikis can provide one or more ways to categorize or tag pages to support the
maintenance of such index pages. Some wikis, including the original, have a <a href="/wiki/Backlink"
title="Backlink">backlink</a> feature, which displays all pages that link to a given page. It is also typically
possible in a wiki to create links to pages that do not yet exist, as a way to invite others to share what they know
about a subject new to the wiki. Wiki users can typically "tag" pages with categories or keywords, to make it easier
for other users to find the article. For example, a user creating a new article on <a
href="/wiki/Cold_weather_cycling" class="mw-redirect" title="Cold weather cycling">cold weather cycling</a> might
"tag" this page under the categories of commuting, winter sports and bicycling. This would make it easier for other
users to find the article.
</p>
<h3><span class="mw-headline" id="Linking_and_creating_pages">Linking and creating pages</span></h3>
<p>Links are created using a specific syntax, the so-called "link pattern". Originally, most wikis<sup
class="noprint Inline-Template Template-Fact" style="white-space:nowrap;">[<i><a
href="/wiki/Wikipedia:Citation_needed" title="Wikipedia:Citation needed"><span
title="This claim needs references to reliable sources. (July 2013)">citation needed</span></a></i>]</sup>
used <a href="/wiki/CamelCase" class="mw-redirect" title="CamelCase">CamelCase</a> to name pages and create links.
These are produced by capitalizing words in a phrase and removing the spaces between them (the word "CamelCase" is
itself an example). While CamelCase makes linking easy, it also leads to links in a form that deviates from the
standard spelling. To link to a page with a single-word title, one must abnormally capitalize one of the letters in
the word (e.g. "WiKi" instead of "Wiki"). CamelCase-based wikis are instantly recognizable because they have many
links with names such as "TableOfContents" and "BeginnerQuestions." It is possible for a wiki to render the visible
anchor of such links "pretty" by reinserting spaces, and possibly also reverting to lower case. This reprocessing of
the link to improve the readability of the anchor is, however, limited by the loss of capitalization information
caused by CamelCase reversal. For example, "RichardWagner" should be rendered as "Richard Wagner", whereas
"PopularMusic" should be rendered as "popular music". There is no easy way to determine which <a
href="/wiki/Capital_letter" class="mw-redirect" title="Capital letter">capital letters</a> should remain
capitalized. As a result, many wikis now have "free linking" using brackets, and some disable CamelCase by default.
<h3><span class="mw-headline" id="Linking_and_creating_pages">Linking and creating pages</span></h3>
</p>
<h3><span class="mw-headline" id="Searching">Searching</span></h3>
<p>Most wikis offer at least a title <a href="/wiki/Search_algorithm" title="Search algorithm">search</a>, and
sometimes a <a href="/wiki/Full_text_search" class="mw-redirect" title="Full text search">full-text search</a>. The
scalability of the search depends on whether the wiki engine uses a database. Some wikis, such as <a
href="/wiki/PmWiki" title="PmWiki">PmWiki</a>, use <a href="/wiki/Flat_file" class="mw-redirect"
title="Flat file">flat files</a>.<sup id="cite_ref-Augar_12-0" class="reference"><a
href="#cite_note-Augar-12">[11]</a></sup> MediaWiki's first versions used flat files, but it was rewritten by <a
href="/wiki/Lee_Daniel_Crocker" title="Lee Daniel Crocker">Lee Daniel Crocker</a> in the early 2000s (decade) to
be a database application.<sup class="noprint Inline-Template Template-Fact" style="white-space:nowrap;">[<i><a
href="/wiki/Wikipedia:Citation_needed" title="Wikipedia:Citation needed"><span
title="This claim needs references to reliable sources. (April 2020)">citation needed</span></a></i>]</sup>
Indexed database access is necessary for high speed searches on large wikis. Alternatively, external <a
href="/wiki/Web_search_engine" title="Web search engine">search engines</a> such as <a href="/wiki/Google_Search"
title="Google Search">Google Search</a> can sometimes be used on wikis with limited searching functions in order
to obtain more precise results.
</p>
<script>
function sendPostMessageResize() {
const resizeEventData = {
height: document.querySelector("input").value
};
let message = {
appKey: "test-id",
messageType: "iframeResize",
data: resizeEventData
};
message = JSON.stringify(message);
window.parent.postMessage(message, "*");
console.log("Mock page has posted message.", `Resize height: ${resizeEventData.height}px`)
}
</script>
</body>
</html>