<?php
/* Smarty version 4.5.3, created on 2024-10-26 08:03:43
  from '/home/w/wmaster77/corp.site-77.ru/public_html/admin/design/html/styles.tpl' */

/* @var Smarty_Internal_Template $_smarty_tpl */
if ($_smarty_tpl->_decodeProperties($_smarty_tpl, array (
  'version' => '4.5.3',
  'unifunc' => 'content_671c782fcb3be8_84515626',
  'has_nocache_code' => false,
  'file_dependency' => 
  array (
    'fa1aba2883b9fd8164bd3132ce578acf89005313' => 
    array (
      0 => '/home/w/wmaster77/corp.site-77.ru/public_html/admin/design/html/styles.tpl',
      1 => 1716650267,
      2 => 'file',
    ),
  ),
  'includes' => 
  array (
  ),
),false)) {
function content_671c782fcb3be8_84515626 (Smarty_Internal_Template $_smarty_tpl) {
if ($_smarty_tpl->tpl_vars['file']->value) {
$_smarty_tpl->_assignInScope('meta_title', "Файл ".((string)$_smarty_tpl->tpl_vars['file']->value) ,false ,8);
} else {
$_smarty_tpl->_assignInScope('meta_title', 'Стили' ,false ,8);
}?>

<div class="container-fluid">

		<div class="nk-block-head nk-block-head-sm">
		<div class="nk-block-between">

						<div class="nk-block-head-content">
				<h3 class="nk-block-title page-title">
					Стили, тема - <?php echo $_smarty_tpl->tpl_vars['settings']->value->theme;?>

				</h3>
				<div class="nk-block-des text-soft">
					<p>Онлайн редактор файлов стилей.</p>
				</div>
			</div>

		</div>
	</div>

		<?php if ($_smarty_tpl->tpl_vars['message_error']->value) {?>
	<div class="pb-2">
		<div class="alert alert-fill alert-danger alert-icon">
			<em class="icon ti ti-circle-x"></em>
			<?php if ($_smarty_tpl->tpl_vars['message_error']->value == 'permissions') {?>
                Установите права на запись для файла <?php echo $_smarty_tpl->tpl_vars['file']->value;?>
.
            <?php } else { ?>
                <?php echo $_smarty_tpl->tpl_vars['message_error']->value;?>
.
            <?php }?>
		</div>
	</div>
	<?php }?>

	    <div class="nk-block-lg mb-3">
        <div class="nk-block-head-xs">
            <div class="nk-block-between g-2">
                <div class="nk-block-head-content">
                    <h6 class="nk-block-title title">Список файлов</h6>
                </div>
            </div>
        </div>
        <div class="nk-files nk-files-view-grid">
            <div class="nk-files-list">

				<?php
$_from = $_smarty_tpl->smarty->ext->_foreach->init($_smarty_tpl, $_smarty_tpl->tpl_vars['styles']->value, 's');
$_smarty_tpl->tpl_vars['s']->do_else = true;
if ($_from !== null) foreach ($_from as $_smarty_tpl->tpl_vars['s']->value) {
$_smarty_tpl->tpl_vars['s']->do_else = false;
?>
				<div class="nk-file-item nk-file">
					<div class="nk-file-info">
						<div class="nk-file-title">
							<div class="nk-file-icon">
								<a class="nk-file-icon-link" href="/admin/index.php?module=StylesAdmin&file=<?php echo $_smarty_tpl->tpl_vars['s']->value;?>
">
									<span class="nk-file-icon-type">
										<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 72 72"><path d="M49,61H23a5.0147,5.0147,0,0,1-5-5V16a5.0147,5.0147,0,0,1,5-5H40.9091L54,22.1111V56A5.0147,5.0147,0,0,1,49,61Z" style="fill:#e3edfc"></path><path d="M54,22.1111H44.1818a3.3034,3.3034,0,0,1-3.2727-3.3333V11s1.8409.2083,6.9545,4.5833C52.8409,20.0972,54,22.1111,54,22.1111Z" style="fill:#b7d0ea"></path><path d="M19.03,59A4.9835,4.9835,0,0,0,23,61H49a4.9835,4.9835,0,0,0,3.97-2Z" style="fill:#c4dbf2"></path><rect x="27" y="31" width="18" height="2" rx="1" ry="1" style="fill:#7e95c4"></rect><rect x="27" y="35" width="18" height="2" rx="1" ry="1" style="fill:#7e95c4"></rect><rect x="27" y="39" width="18" height="2" rx="1" ry="1" style="fill:#7e95c4"></rect><rect x="27" y="43" width="14" height="2" rx="1" ry="1" style="fill:#7e95c4"></rect><rect x="27" y="47" width="8" height="2" rx="1" ry="1" style="fill:#7e95c4"></rect></svg>
									</span>
								</a>
							</div>
							<div class="nk-file-name">
								<div class="nk-file-name-text">
									<a href="/admin/index.php?module=StylesAdmin&file=<?php echo $_smarty_tpl->tpl_vars['s']->value;?>
" class="title <?php if ($_smarty_tpl->tpl_vars['file']->value == $_smarty_tpl->tpl_vars['s']->value) {?>text-primary<?php }?>"><?php echo $_smarty_tpl->tpl_vars['s']->value;?>
</a>
								</div>
							</div>
						</div>
					</div>
				</div>
				<?php
}
$_smarty_tpl->smarty->ext->_foreach->restore($_smarty_tpl, 1);?>

			</div>
		</div>
	</div>

		<div class="nk-block">
		<div class="card card-bordered">
			<div class="card-inner card-inner-xs">

								<div class="nk-block-head nk-block-head-lg pb-2">
					<div class="nk-block-between">

												<div class="nk-block-head-content">
							<h4 class="nk-block-title">
								Файл <?php echo $_smarty_tpl->tpl_vars['file']->value;?>

							</h4>
							<div class="nk-block-des">
								<p>
									Выберите файл для редактирования из списка. Для быстрого сохранения можно использовать комбинацию клавиш CTRL+S.
								</p>
							</div>
						</div>

												<div class="nk-block-head-content align-self-start d-lg-none">
							<a href="#" class="toggle btn btn-icon btn-trigger mt-n1" data-target="userAside">
								<em class="icon ti ti-menu"></em>
							</a>
						</div>
					</div>
				</div>

								<?php if ($_smarty_tpl->tpl_vars['file']->value && !$_smarty_tpl->tpl_vars['message_error']->value) {?>
				<div class="nk-block js-template-style" data-theme="<?php echo $_smarty_tpl->tpl_vars['settings']->value->theme;?>
" data-style="<?php echo $_smarty_tpl->tpl_vars['file']->value;?>
">
					<form>
						<div class="nk-data">
							<div class="template-editor w-100">
								<div class="form-group">
									<textarea id="content" name="content" class="form-control"><?php echo htmlspecialchars((string)$_smarty_tpl->tpl_vars['content']->value, ENT_QUOTES, 'UTF-8', true);?>
</textarea>
								</div>
								<div class="form-group">
									<button type="button" class="btn btn-success js-template-save">Сохранить</button>
								</div>
							</div>
						</div>
					</form>
				</div>
				<?php }?>
			</div>

		</div>
	</div>
</div>
<?php }
}
