93 lines
5.8 KiB
Plaintext
93 lines
5.8 KiB
Plaintext
@model RelationshipMapViewModel
|
||
@{
|
||
ViewData["Title"] = $"Relationships - {Model.Project.ProjectName}";
|
||
ViewData["ProjectSection"] = "Relationships";
|
||
ViewData["ShellClass"] = "plotline-shell-wide rw-shell";
|
||
}
|
||
<link rel="stylesheet" href="~/css/relationship-workspace.css" asp-append-version="true" />
|
||
<section id="rwApp" class="rw-app" aria-label="Relationships workspace">
|
||
<header class="rw-toolbar" data-pd-context="workspace">
|
||
<h1 data-pwa-help>Relationships <help-icon key="relationshipMap.overview" /></h1>
|
||
<div class="rw-view-switch" data-pwa-context="View" role="group" aria-label="Workspace view">
|
||
<button type="button" class="btn btn-sm" id="rwMapView" aria-pressed="true">Map</button>
|
||
<button type="button" class="btn btn-sm" id="rwListView" aria-pressed="false">List</button>
|
||
</div>
|
||
<div class="rw-focus-chip" data-pwa-context="Focus"><button type="button" id="rwFocusName" title="Centre focused character">Full cast</button><button type="button" id="rwClearFocus" aria-label="Clear character focus" hidden>×</button></div>
|
||
<div class="rw-toolbar-actions">
|
||
<button type="button" class="btn btn-outline-secondary btn-sm rw-mobile-only" id="rwCharacters" aria-expanded="false">Characters</button>
|
||
<button type="button" class="btn btn-outline-secondary btn-sm" data-pwa-context="Relationship" id="rwInfo" aria-expanded="false">Details</button>
|
||
<button type="button" class="btn btn-outline-secondary btn-sm" data-pwa-context="Relationship" id="rwConnect">Add relationship</button>
|
||
<button class="btn btn-outline-secondary btn-sm rw-arrange" type="button" data-map-reset data-pwa-context="Arrange">Auto-arrange</button>
|
||
<details class="rw-menu" data-pwa-context="Layout" data-pwa-compact="true"><summary class="btn btn-outline-secondary btn-sm">Layout</summary><div class="rw-menu-panel">
|
||
<button class="btn btn-outline-secondary btn-sm" type="button" id="rwRemove">Remove focused from map</button>
|
||
<button class="btn btn-outline-secondary btn-sm" type="button" id="rwReset">Reset layout</button>
|
||
<button type="button" class="btn btn-outline-secondary btn-sm" id="rwPalettes" aria-expanded="true">Characters</button>
|
||
</div></details>
|
||
<details class="rw-menu rw-display" data-pwa-context="Display" data-pwa-scope="Display" data-pwa-compact="true"><summary class="btn btn-outline-secondary btn-sm">Display</summary><div class="rw-menu-panel">
|
||
<form class="relationship-map-controls" method="get" asp-action="Index">
|
||
<input type="hidden" name="projectId" value="@Model.Project.ProjectID" />
|
||
<div>
|
||
<label class="form-label" for="bookId">Book</label>
|
||
<select class="form-select form-select-sm" id="bookId" name="bookId" asp-items="Model.BookOptions">
|
||
<option value="">Project Start</option>
|
||
</select>
|
||
</div>
|
||
<div>
|
||
<label class="form-label" for="chapterId">Chapter</label>
|
||
<select class="form-select form-select-sm" id="chapterId" name="chapterId" asp-items="Model.ChapterOptions">
|
||
<option value="">Any chapter</option>
|
||
</select>
|
||
</div>
|
||
<div>
|
||
<label class="form-label" for="sceneId">Scene</label>
|
||
<select class="form-select form-select-sm" id="sceneId" name="sceneId" asp-items="Model.SceneOptions">
|
||
<option value="">Any scene</option>
|
||
</select>
|
||
</div>
|
||
<div>
|
||
<label class="form-label" for="focusCharacterId">Character focus</label>
|
||
<select class="form-select form-select-sm" id="focusCharacterId" name="focusCharacterId" asp-items="Model.CharacterOptions">
|
||
<option value="">Full cast</option>
|
||
</select>
|
||
</div>
|
||
<label class="form-check relationship-map-check">
|
||
<input class="form-check-input" type="checkbox" name="showFullNetwork" value="true" checked="@Model.ShowFullNetwork" />
|
||
<span class="form-check-label">Show full network</span>
|
||
</label>
|
||
<button class="btn btn-primary btn-sm" type="submit">Update Map</button>
|
||
<a class="btn btn-outline-secondary btn-sm" asp-action="Index" asp-route-projectId="@Model.Project.ProjectID">Project Start</a>
|
||
</form>
|
||
<div class="relationship-map-legend-grid" data-pwa-ribbon-content>
|
||
@foreach (var category in Model.Categories)
|
||
{
|
||
<span class="relationship-map-legend-item @category.CssClass">
|
||
<span class="relationship-map-legend-line" aria-hidden="true"></span>
|
||
<span>@category.CategoryName</span>
|
||
</span>
|
||
}
|
||
</div>
|
||
|
||
</div></details>
|
||
<button type="button" data-pwa-context="Display" data-pwa-compact="true" id="rwMaximise" class="btn btn-outline-secondary btn-sm" aria-label="Maximise workspace" aria-pressed="false" title="Maximise workspace">⛶</button>
|
||
</div>
|
||
</header>
|
||
<partial name="_Workspace" model="Model" />
|
||
<div id="rwListPanel" class="rw-list-panel" hidden aria-label="Relationship list">
|
||
<h2>Relationships at the current story point</h2>
|
||
<div class="relationship-map-list">
|
||
@foreach (var relationship in Model.Relationships)
|
||
{
|
||
<button data-pd-context="relationship" data-pd-context-id="@relationship.CharacterRelationshipID" data-pd-context-label="Select relationship" data-pwa-icon="relationships" class="relationship-map-list-item" type="button" data-map-select="@relationship.CharacterRelationshipID">
|
||
<strong>@relationship.CharacterAName - @relationship.CharacterBName</strong>
|
||
<span>@relationship.CurrentStateName</span>
|
||
<span class="status-pill @relationship.CssClass">@relationship.RelationshipCategoryName</span>
|
||
</button>
|
||
}
|
||
</div>
|
||
|
||
</div>
|
||
</section>
|
||
@section Scripts {
|
||
<partial name="_GraphScripts" model="Model" />
|
||
}
|