<commit_before>{* $Id$ *}

{title admpage="wiki"}{tr}History:{/tr} {$page}{/title}

<div class="t_navbar margin-bottom-md">
	{assign var=thispage value=$page|escape:url}
	{button href="tiki-index.php?page=$thispage" class="btn btn-default" _text="{tr}View page{/tr}"}
	{if !isset($noHistory)}
		{if $show_all_versions eq "y"}
			{button _text="{tr}Show Edit Sessions{/tr}" show_all_versions="n" href="?clear_versions=1" _auto_args="*" class="btn btn-default"}
		{else}
			{button _text="{tr}Show All Versions{/tr}" show_all_versions="y" href="?clear_versions=1" _auto_args="*" class="btn btn-default"}
		{/if}
	{/if}
</div>

{if $preview}
	<h2>{tr}Preview of version:{/tr} {$preview}
		{if $info.version eq $preview}<small><small>{tr}(current){/tr}</small></small>{/if}
	</h2>
	{if $info.version ne $preview and $tiki_p_rollback eq 'y'}
		<div class="navbar">
			{self_link _script="tiki-rollback.php" page=$page version=$preview _title="{tr}Rollback{/tr}"}{tr}Rollback to this version{/tr}{/self_link}
		</div>
	{/if}
	<div>
		{if !isset($noHistory)}
			{if isset($show_all_versions) and $show_all_versions eq "n"}
				{pagination_links cant=$ver_cant offset=$smarty.request.preview_idx offset_arg="preview_idx" itemname="{tr}Session{/tr}" show_numbers="n"}{/pagination_links}
			{else}
				{pagination_links cant=$ver_cant offset=$smarty.request.preview_idx offset_arg="preview_idx" itemname="{tr}Version{/tr}" show_numbers="n" _keepall="n"}{/pagination_links}
			{/if}
		{/if}
	</div>
	{if (isset($flaggedrev_approval) and $flaggedrev_approval) and $tiki_p_wiki_approve eq 'y'}
		{remarksbox type=comment title="{tr}Content Approval{/tr}"}
			<form method="post" action="tiki-pagehistory.php?page={$page|escape:'url'}&amp;preview={$preview|escape:'url'}">
				{if $flaggedrev_preview_approved}
					<p>{tr}This revision is currently marked as approved.{/tr}<p>
					<div class="submit">
						<input type="hidden" name="unapprove" value="{$preview|escape}">
						<input type="submit" class="btn btn-default btn-sm" name="flaggedrev" value="{tr}Remove Approval{/tr}">
					</div>
				{else}
					<p>{tr}This revision has not been approved.{/tr}<p>
					<div class="submit">
						<input type="hidden" name="approve" value="{$preview|escape}">
						<input type="submit" class="btn btn-default btn-sm" name="flaggedrev" value="{tr}Approve Revision{/tr}">
					</div>
				{/if}
			</form>
		{/remarksbox}
	{/if}
	<div class="wikitext" id="page-data">
		{$previewd}
	</div>
{/if}

{if $source}
	<h2>
		{tr}Source of version:{/tr} {$source}
		{if $info.version eq $source}<small><small>{tr}(current){/tr}</small></small>{/if}
	</h2>
	{if $info.version ne $source and $tiki_p_rollback eq 'y'}
		<div class="navbar">{self_link _script="tiki-rollback.php" page=$page version=$source _title="{tr}Rollback{/tr}"}{tr}Rollback to this version{/tr}{/self_link}</div>
	{/if}
	<div>
		{if !isset($noHistory)}
			{if isset($show_all_versions) and $show_all_versions eq "n"}
				{pagination_links cant=$ver_cant offset=$smarty.request.source_idx offset_arg="source_idx" itemname="{tr}Session{/tr}" show_numbers="n"}{/pagination_links}
			{else}
				{pagination_links cant=$ver_cant offset=$smarty.request.source_idx offset_arg="source_idx" itemname="{tr}Version{/tr}" show_numbers="n" _keepall="n"}{/pagination_links}
			{/if}
		{/if}
	</div>
	<textarea data-codemirror="true" data-syntax='tiki' class="wikiedit readonly" style="width:100%;height:400px" readonly="readonly" id="page_source">{$sourced|escape}</textarea>
	{if $prefs.feature_jquery_ui eq "y" && $prefs.feature_syntax_highlighter neq "y"}{jq}$("#page_source").resizable();{/jq}{/if}
{/if}

{if (isset($flaggedrev_approval) and $flaggedrev_approval) and $tiki_p_wiki_approve eq 'y' and $flaggedrev_compare_approve}
	{remarksbox type=comment title="{tr}Content Approval{/tr}"}
		<form method="post" action="tiki-pagehistory.php?page={$page|escape:'url'}&amp;preview={$new.version|escape:'url'}">
			<p>{tr}This revision has not been approved.{/tr}<p>
			<div class="submit">
				<input type="hidden" name="approve" value="{$new.version|escape}">
				<input type="submit" class="btn btn-default btn-sm" name="flaggedrev" value="{tr}Approve Revision{/tr}">
			</div>
		</form>
	{/remarksbox}
{/if}

{include file='pagehistory.tpl'}

<hr style="clear: both;"/>

{if !isset($noHistory)}
	{if $preview || $source || $diff_style}<h2>{tr}History{/tr}</h2>{/if}
	<form id="pagehistory" class="form-horizontal" action="tiki-pagehistory.php?page={$page}" method="post">
		<input type="hidden" name="page" value="{$page|escape}">
		<input type="hidden" name="history_offset" value="{$history_offset}">
		<div>
			{if ($prefs.default_wiki_diff_style ne "old") and $history}
				<div class="input-group col-sm-5 pull-right">
					<select class="form-control" name="diff_style" id="diff_style_all"{if $prefs.javascript_enabled eq "y"} style="display: none"{/if}>
						<option value="htmldiff" {if $diff_style == "htmldiff"}selected="selected"{/if}>
							{tr}HTML diff{/tr}
						</option>
						<option value="sidediff" {if $diff_style == "sidediff"}selected="selected"{/if}>
							{tr}Side-by-side diff{/tr}
						</option>
						<option value="sidediff-char" {if $diff_style == "sidediff-char"}selected="selected"{/if}>
							{tr}Side-by-side diff by characters{/tr}
						</option>
						<option value="inlinediff" {if $diff_style == "inlinediff"}selected="selected"{/if}>
							{tr}Inline diff{/tr}
						</option>
						<option value="inlinediff-char" {if $diff_style == "inlinediff-char"}selected="selected"{/if}>
							{tr}Inline diff by characters{/tr}
						</option>
						<option value="sidediff-full" {if $diff_style == "sidediff-full"}selected="selected"{/if}>
							{tr}Full side-by-side diff{/tr}
						</option>
						<option value="sidediff-full-char" {if $diff_style == "sidediff-full-char"}selected="selected"{/if}>
							{tr}Full side-by-side diff by characters{/tr}
						</option>
						<option value="inlinediff-full" {if $diff_style == "inlinediff-full"}selected="selected"{/if}>
							{tr}Full inline diff{/tr}
						</option>
						<option value="inlinediff-full-char" {if $diff_style == "inlinediff-full-char"}selected="selected"{/if}>
							{tr}Full inline diff by characters{/tr}
						</option>
						<option value="unidiff" {if $diff_style == "unidiff"}selected="selected"{/if}>
							{tr}Unified diff{/tr}
						</option>
						<option value="sideview" {if $diff_style == "sideview"}selected="selected"{/if}>
							{tr}Side-by-side view{/tr}
						</option>
					</select>
					{if $prefs.javascript_enabled eq "y"}
						<select class="form-control" name="diff_style" id="diff_style_simple" style="float:right">
							<option value="htmldiff" {if $diff_style == "htmldiff"}selected="selected"{/if}>
								{tr}HTML diff{/tr}
							</option>
							<option value="sidediff" {if $diff_style == "sidediff"}selected="selected"{/if}><commit_msg>[FIX] compare button was overlapped by the view mode selection<commit_after>{* $Id$ *}

{title admpage="wiki"}{tr}History:{/tr} {$page}{/title}

<div class="t_navbar margin-bottom-md">
	{assign var=thispage value=$page|escape:url}
	{button href="tiki-index.php?page=$thispage" class="btn btn-default" _text="{tr}View page{/tr}"}
	{if !isset($noHistory)}
		{if $show_all_versions eq "y"}
			{button _text="{tr}Show Edit Sessions{/tr}" show_all_versions="n" href="?clear_versions=1" _auto_args="*" class="btn btn-default"}
		{else}
			{button _text="{tr}Show All Versions{/tr}" show_all_versions="y" href="?clear_versions=1" _auto_args="*" class="btn btn-default"}
		{/if}
	{/if}
</div>

{if $preview}
	<h2>{tr}Preview of version:{/tr} {$preview}
		{if $info.version eq $preview}<small><small>{tr}(current){/tr}</small></small>{/if}
	</h2>
	{if $info.version ne $preview and $tiki_p_rollback eq 'y'}
		<div class="navbar">
			{self_link _script="tiki-rollback.php" page=$page version=$preview _title="{tr}Rollback{/tr}"}{tr}Rollback to this version{/tr}{/self_link}
		</div>
	{/if}
	<div>
		{if !isset($noHistory)}
			{if isset($show_all_versions) and $show_all_versions eq "n"}
				{pagination_links cant=$ver_cant offset=$smarty.request.preview_idx offset_arg="preview_idx" itemname="{tr}Session{/tr}" show_numbers="n"}{/pagination_links}
			{else}
				{pagination_links cant=$ver_cant offset=$smarty.request.preview_idx offset_arg="preview_idx" itemname="{tr}Version{/tr}" show_numbers="n" _keepall="n"}{/pagination_links}
			{/if}
		{/if}
	</div>
	{if (isset($flaggedrev_approval) and $flaggedrev_approval) and $tiki_p_wiki_approve eq 'y'}
		{remarksbox type=comment title="{tr}Content Approval{/tr}"}
			<form method="post" action="tiki-pagehistory.php?page={$page|escape:'url'}&amp;preview={$preview|escape:'url'}">
				{if $flaggedrev_preview_approved}
					<p>{tr}This revision is currently marked as approved.{/tr}<p>
					<div class="submit">
						<input type="hidden" name="unapprove" value="{$preview|escape}">
						<input type="submit" class="btn btn-default btn-sm" name="flaggedrev" value="{tr}Remove Approval{/tr}">
					</div>
				{else}
					<p>{tr}This revision has not been approved.{/tr}<p>
					<div class="submit">
						<input type="hidden" name="approve" value="{$preview|escape}">
						<input type="submit" class="btn btn-default btn-sm" name="flaggedrev" value="{tr}Approve Revision{/tr}">
					</div>
				{/if}
			</form>
		{/remarksbox}
	{/if}
	<div class="wikitext" id="page-data">
		{$previewd}
	</div>
{/if}

{if $source}
	<h2>
		{tr}Source of version:{/tr} {$source}
		{if $info.version eq $source}<small><small>{tr}(current){/tr}</small></small>{/if}
	</h2>
	{if $info.version ne $source and $tiki_p_rollback eq 'y'}
		<div class="navbar">{self_link _script="tiki-rollback.php" page=$page version=$source _title="{tr}Rollback{/tr}"}{tr}Rollback to this version{/tr}{/self_link}</div>
	{/if}
	<div>
		{if !isset($noHistory)}
			{if isset($show_all_versions) and $show_all_versions eq "n"}
				{pagination_links cant=$ver_cant offset=$smarty.request.source_idx offset_arg="source_idx" itemname="{tr}Session{/tr}" show_numbers="n"}{/pagination_links}
			{else}
				{pagination_links cant=$ver_cant offset=$smarty.request.source_idx offset_arg="source_idx" itemname="{tr}Version{/tr}" show_numbers="n" _keepall="n"}{/pagination_links}
			{/if}
		{/if}
	</div>
	<textarea data-codemirror="true" data-syntax='tiki' class="wikiedit readonly" style="width:100%;height:400px" readonly="readonly" id="page_source">{$sourced|escape}</textarea>
	{if $prefs.feature_jquery_ui eq "y" && $prefs.feature_syntax_highlighter neq "y"}{jq}$("#page_source").resizable();{/jq}{/if}
{/if}

{if (isset($flaggedrev_approval) and $flaggedrev_approval) and $tiki_p_wiki_approve eq 'y' and $flaggedrev_compare_approve}
	{remarksbox type=comment title="{tr}Content Approval{/tr}"}
		<form method="post" action="tiki-pagehistory.php?page={$page|escape:'url'}&amp;preview={$new.version|escape:'url'}">
			<p>{tr}This revision has not been approved.{/tr}<p>
			<div class="submit">
				<input type="hidden" name="approve" value="{$new.version|escape}">
				<input type="submit" class="btn btn-default btn-sm" name="flaggedrev" value="{tr}Approve Revision{/tr}">
			</div>
		</form>
	{/remarksbox}
{/if}

{include file='pagehistory.tpl'}

<hr style="clear: both;"/>

{if !isset($noHistory)}
	{if $preview || $source || $diff_style}<h2>{tr}History{/tr}</h2>{/if}
	<form id="pagehistory" class="form-horizontal" action="tiki-pagehistory.php?page={$page}" method="post">
		<input type="hidden" name="page" value="{$page|escape}">
		<input type="hidden" name="history_offset" value="{$history_offset}">
		<div class="clearfix">
			{if ($prefs.default_wiki_diff_style ne "old") and $history}
				<div class="input-group input-group-sm col-sm-5 pull-right">
					<select class="form-control" name="diff_style" id="diff_style_all"{if $prefs.javascript_enabled eq "y"} style="display: none"{/if}>
						<option value="htmldiff" {if $diff_style == "htmldiff"}selected="selected"{/if}>
							{tr}HTML diff{/tr}
						</option>
						<option value="sidediff" {if $diff_style == "sidediff"}selected="selected"{/if}>
							{tr}Side-by-side diff{/tr}
						</option>
						<option value="sidediff-char" {if $diff_style == "sidediff-char"}selected="selected"{/if}>
							{tr}Side-by-side diff by characters{/tr}
						</option>
						<option value="inlinediff" {if $diff_style == "inlinediff"}selected="selected"{/if}>
							{tr}Inline diff{/tr}
						</option>
						<option value="inlinediff-char" {if $diff_style == "inlinediff-char"}selected="selected"{/if}>
							{tr}Inline diff by characters{/tr}
						</option>
						<option value="sidediff-full" {if $diff_style == "sidediff-full"}selected="selected"{/if}>
							{tr}Full side-by-side diff{/tr}
						</option>
						<option value="sidediff-full-char" {if $diff_style == "sidediff-full-char"}selected="selected"{/if}>
							{tr}Full side-by-side diff by characters{/tr}
						</option>
						<option value="inlinediff-full" {if $diff_style == "inlinediff-full"}selected="selected"{/if}>
							{tr}Full inline diff{/tr}
						</option>
						<option value="inlinediff-full-char" {if $diff_style == "inlinediff-full-char"}selected="selected"{/if}>
							{tr}Full inline diff by characters{/tr}
						</option>
						<option value="unidiff" {if $diff_style == "unidiff"}selected="selected"{/if}>
							{tr}Unified diff{/tr}
						</option>
						<option value="sideview" {if $diff_style == "sideview"}selected="selected"{/if}>
							{tr}Side-by-side view{/tr}
						</option>
					</select>
					{if $prefs.javascript_enabled eq "y"}
						<select class="form-control" name="diff_style" id="diff_style_simple">
							<option value="htmldiff" {if $diff_style == "htmldiff"}selected="selected"{/if}>
								{tr}HTML diff{/tr}
							</option>
							<option value="sidediff" {if $diff_style == "sidediff"}selected="selected"{/if}>
{'fraction_non_alphanumeric': 0.19692285570493925, 'fraction_numerical': 0.0021568768423323027, 'mean_word_length': 5.082203760384783, 'pattern_counts': {'":': 0, '<': 171, '<?xml version=': 0, '>': 171, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4203799', 'n_tokens_mistral': 5824, 'n_tokens_neox': 5047, 'n_words': 915}