OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
Remove old SPOT docs page
Benjamin Bädorf2df7ee7fa1a0
diff --git a/config/routes.rb b/config/routes.rbindex 044f8ea5d2c..e8f09962200 100644--- a/config/routes.rb+++ b/config/routes.rb@@ -580,6 +580,5 @@ OpenProject::Application.routes.draw doend# Routes for design related documentation and examples pages- get '/design/spot', to: 'angular#empty_layout'get '/design/styleguide' => redirect('/assets/styleguide.html')enddiff --git a/frontend/src/app/spot/spot-docs.component.html b/frontend/src/app/spot/spot-docs.component.htmldeleted file mode 100644index a0aa67f1a22..00000000000--- a/frontend/src/app/spot/spot-docs.component.html+++ /dev/null@@ -1,662 +0,0 @@-<h1>Buttons & Links</h1>-<section class="space-children">- <button class="spot-button">Default</button>- <button class="spot-button">- <span>Default</span>- <span class="spot-icon spot-icon_bell"></span>- </button>- <button class="spot-button"><span class="spot-icon spot-icon_bell"></span></button>-</section>--<section class="space-children">- <button class="spot-button spot-button_main">Main</button>- <button class="spot-button spot-button_main">- <span>Main</span>- <span class="spot-icon spot-icon_bell"></span>- </button>- <button class="spot-button spot-button_main"><span class="spot-icon spot-icon_bell"></span></button>-</section>--<section class="space-children">- <button class="spot-button spot-button_accent">Accent</button>- <button class="spot-button spot-button_accent">- <span>Accent</span>- <span class="spot-icon spot-icon_bell"></span>- </button>- <button class="spot-button spot-button_accent"><span class="spot-icon spot-icon_bell"></span></button>-</section>--<section class="space-children">- <button class="spot-button spot-button_danger">Danger</button>- <button class="spot-button spot-button_danger">- <span>Danger</span>- <span class="spot-icon spot-icon_bell"></span>- </button>- <button class="spot-button spot-button_danger"><span class="spot-icon spot-icon_bell"></span></button>-</section>--<section class="space-children">- <button class="spot-button" disabled>Disabled</button>- <button class="spot-button" disabled>- <span>Disabled</span>- <span class="spot-icon spot-icon_bell"></span>- </button>- <button class="spot-button" disabled><span class="spot-icon spot-icon_bell"></span></button>-</section>--<section class="space-children">- <button class="spot-button spot-button_outlined">Default</button>- <button class="spot-button spot-button_outlined spot-button_main">Main</button>- <button class="spot-button spot-button_outlined spot-button_accent">Accent</button>- <button class="spot-button spot-button_outlined spot-button_danger">Danger</button>- <button class="spot-button spot-button_outlined" disabled>Disabled</button>-</section>--<section class="space-children">- <button class="spot-link">Default link</button>- <a class="spot-link" href="#">- <span>Default Link</span>- <span class="spot-icon spot-icon_bell"></span>- </a>- <a class="spot-link" href="#">- <span class="spot-icon spot-icon_bell"></span>- <span>Default Link</span>- </a>- <button class="spot-link"><span class="spot-icon spot-icon_bell"></span></button>-</section>--<section class="space-children">- <button class="spot-link spot-link_danger">Danger Link</button>- <a class="spot-link spot-link_danger" href="#">- <span>Danger Link</span>- <span class="spot-icon spot-icon_bell"></span>- </a>- <a class="spot-link spot-link_danger" href="#">- <span class="spot-icon spot-icon_bell"></span>- <span>Danger Link</span>- </a>- <button class="spot-link spot-link_danger"><span class="spot-icon spot-icon_bell"></span></button>-</section>--<h1>Toggles</h1>--<spot-toggle- [options]="toggleOptions"- [(ngModel)]="toggleValue"-></spot-toggle>-Currently selected value is {{ toggleValue }}--<h1>Checkbox</h1>--<label>- <spot-checkbox></spot-checkbox>- Unchecked-</label>--<label>- <spot-checkbox [checked]="true"></spot-checkbox>- Checked-</label>--<label>- <spot-checkbox [disabled]="true"></spot-checkbox>- Disabled-</label>--<label>- <spot-checkbox- [checked]="true"- [disabled]="true"- ></spot-checkbox>- Disabled checked-</label>--<label>- <spot-checkbox [(ngModel)]="checkboxValue"></spot-checkbox>- Currently {{ checkboxValueString() }}-</label>--<label>- <spot-checkbox- [(ngModel)]="checkboxValue"- [disabled]="true"- name="checkbox-name"- ></spot-checkbox>- Currently {{ checkboxValueString() }}-</label>--<h1>Lists</h1>--<h2>Normal list</h2>--<p>HINT: To enable floating actions on hover, every <i>spot-list--item</i> needs a- <i>spot-list--item-floating-wrapper</i>, which wraps the item's content and the <i>spot-list-item-floating-actions</i>,- but not any sub lists. This way, floating actions on hover are defined specific for each item, hence in the same list- items with floating actions can be right next to items without.</p>--<ul class="spot-list">- <li class="spot-list--item">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Checkbox item</div>- </label>- </li>- <li class="spot-list--item">- <div class="spot-list--item-floating-wrapper">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Checkbox item with hover menu</div>- </label>- <div class="spot-list--item-floating-actions">- <button class="spot-link">- <span class="spot-icon spot-icon_folder-open"></span>- </button>- <button class="spot-link">- <span class="spot-icon spot-icon_external-link"></span>- </button>- <button class="spot-link">- <span class="spot-icon spot-icon_file-doc"></span>- </button>- </div>- </div>- </li>- <li class="spot-list--item">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Checkbox item with children</div>- </label>- <ul class="spot-list">- <li class="spot-list--item">- <div class="spot-list--item-floating-wrapper">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Child checkbox item</div>- </label>- <div class="spot-list--item-floating-actions">- <button class="spot-link">- <span class="spot-icon spot-icon_folder-open"></span>- </button>- <button class="spot-link">- <span class="spot-icon spot-icon_file-doc"></span>- </button>- </div>- </div>- <ul class="spot-list">- <li class="spot-list--item">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Second level child</div>- </label>- </li>- </ul>- </li>- <li class="spot-list--item">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Second child checkbox item</div>- </label>- </li>- <li class="spot-list--item">- <div class="spot-list--item-floating-wrapper">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Second child checkbox item with hover menu</div>- </label>- <div class="spot-list--item-floating-actions">- <button class="spot-link">- <span class="spot-icon spot-icon_folder-open"></span>- </button>- <button class="spot-link">- <span class="spot-icon spot-icon_file-doc"></span>- </button>- </div>- </div>- </li>- <li class="spot-list--item">- <label class="spot-list--item-action spot-list--item-action_disabled">- <spot-checkbox- [(ngModel)]="listCheckboxValue"- [disabled]="true"- ></spot-checkbox>- <div class="spot-list--item-title">Disabled item</div>- </label>- </li>- </ul>- </li>-</ul>--<h2>Compact list</h2>--<ul class="spot-list spot-list_compact">- <li class="spot-list--item">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Checkbox item</div>- </label>- </li>- <li class="spot-list--item">- <div class="spot-list--item-floating-wrapper">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Checkbox item with hover menu</div>- </label>- <div class="spot-list--item-floating-actions">- <button class="spot-link">- <span class="spot-icon spot-icon_folder-open"></span>- </button>- <button class="spot-link">- <span class="spot-icon spot-icon_external-link"></span>- </button>- <button class="spot-link">- <span class="spot-icon spot-icon_file-doc"></span>- </button>- </div>- </div>- </li>- <li class="spot-list--item">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Checkbox item with children</div>- </label>- <ul class="spot-list spot-list_compact">- <li class="spot-list--item">- <div class="spot-list--item-floating-wrapper">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Child checkbox item</div>- </label>- <div class="spot-list--item-floating-actions">- <button class="spot-link">- <span class="spot-icon spot-icon_folder-open"></span>- </button>- <button class="spot-link">- <span class="spot-icon spot-icon_file-doc"></span>- </button>- </div>- </div>- <ul class="spot-list spot-list_compact">- <li class="spot-list--item">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Second level child</div>- </label>- </li>- </ul>- </li>- <li class="spot-list--item">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Second child checkbox item</div>- </label>- </li>- <li class="spot-list--item">- <div class="spot-list--item-floating-wrapper">- <label class="spot-list--item-action">- <spot-checkbox [(ngModel)]="listCheckboxValue"></spot-checkbox>- <div class="spot-list--item-title">Second child checkbox item with hover menu</div>- </label>- <div class="spot-list--item-floating-actions">- <button class="spot-link">- <span class="spot-icon spot-icon_folder-open"></span>- </button>- <button class="spot-link">- <span class="spot-icon spot-icon_file-doc"></span>- </button>- </div>- </div>- </li>- <li class="spot-list--item">- <label class="spot-list--item-action spot-list--item-action_disabled">- <spot-checkbox- [(ngModel)]="listCheckboxValue"- [disabled]="true"- ></spot-checkbox>- <div class="spot-list--item-title">Disabled item</div>- </label>- </li>- </ul>- </li>-</ul>--<h1>Filter Chip</h1>--<section class="space-children">- <spot-filter-chip- title="Default chip"- (remove)="onRemoveChip()"- ></spot-filter-chip>-- <spot-filter-chip- title="Unremovable chip"- [removable]="false"- ></spot-filter-chip>-- <spot-filter-chip- title="Default chip with icon"- icon="bell"- (remove)="onRemoveChip()"- ></spot-filter-chip>-- <spot-filter-chip- icon="bell"- title="Unremovable chip with icon"- [removable]="false"- ></spot-filter-chip>-</section>--<section class="space-children">- <spot-filter-chip- title="Default chip"- (remove)="onRemoveChip()"- [disabled]="true"- ></spot-filter-chip>-- <spot-filter-chip- title="Unremovable chip"- [removable]="false"- [disabled]="true"- ></spot-filter-chip>-- <spot-filter-chip- title="Default chip with icon"- icon="bell"- (remove)="onRemoveChip()"- [disabled]="true"- ></spot-filter-chip>-- <spot-filter-chip- icon="bell"- title="Unremovable chip with icon"- [removable]="false"- [disabled]="true"- ></spot-filter-chip>-</section>--<h1>Text Field</h1>--<section class="space-children">- <input- class="spot-text-field"- placeholder="Placeholder value"- />-- <input- class="spot-text-field"- value="Test value"- />-- <spot-text-field- placeholder="Placeholder value"- value="Test value"- name="textfield-name"- ></spot-text-field>-- <spot-text-field- placeholder="Placeholder value"- [(ngModel)]="textFieldValue"- ></spot-text-field>-- <spot-text-field- placeholder="Placeholder value"- [(ngModel)]="textFieldValue"- >- <span- slot="after"- class="spot-icon spot-icon_bell"- ></span>- </spot-text-field>-- <spot-text-field- placeholder="Placeholder value"- [(ngModel)]="textFieldValue"- >- <span- slot="before"- class="spot-icon spot-icon_bell"- ></span>- <span- slot="after"- class="spot-icon spot-icon_bell"- ></span>- </spot-text-field>-- <spot-text-field- placeholder="Placeholder value"- [(ngModel)]="textFieldValue"- >- <span- slot="before"- class="spot-icon spot-icon_bell"- ></span>- </spot-text-field>-- <spot-text-field- placeholder="Disabled"- [disabled]="true"- >- <span- slot="before"- class="spot-icon spot-icon_bell"- ></span>- </spot-text-field>-</section>--<h1>Form Field</h1>--<section class="space-children">- <spot-form-field label="Some input">- <spot-text-field- slot="input"- [(ngModel)]="textFieldValue"- ></spot-text-field>-- <p- slot="description"- class="spot-form-field--description"- >This is a description for the form field</p>- </spot-form-field>-- <form- [formGroup]="usernameForm"- (ngSubmit)="onUsernameSubmit()"- >- <spot-form-field- label="Validated input"- [required]="true"- >- <spot-text-field- slot="input"- formControlName="username"- >- <span- slot="before"- class="spot-icon spot-icon_user"- ></span>- </spot-text-field>-- <p- slot="description"- class="spot-form-field--description"- >- This field has validation; try typing in it. The current value is "{{ usernameForm.get('username')!.value }}"- </p>-- <p- slot="errors"- class="spot-form-field--error"- *ngIf="usernameForm.get('username')!.errors?.required"- >- This field is required- </p>-- <p- slot="errors"- class="spot-form-field--error"- *ngIf="usernameForm.get('username')!.errors?.minlength"- >- A username must have at least 3 characters- </p>- <p- slot="errors"- class="spot-form-field--error"- *ngIf="usernameForm.get('username')!.errors?.maxlength"- >- A username must have at most 5 characters- </p>- </spot-form-field>- </form>-</section>--<h1>Drop Modal</h1>--<select [(ngModel)]="dropModalAlignment">- <option>left-top</option>- <option>left-center</option>- <option>left-bottom</option>- <option>top-left</option>- <option>top-center</option>- <option>top-right</option>- <option>right-top</option>- <option>right-center</option>- <option>right-bottom</option>- <option>bottom-left</option>- <option>bottom-center</option>- <option>bottom-right</option>-</select>--<spot-drop-modal- [open]="dropModalOpen"- [alignment]="dropModalAlignment"- (closed)="dropModalOpen = false"->- <button- slot="trigger"- type="button"- class="spot-button spot-button_main"- (click)="dropModalOpen = !dropModalOpen"- >Open Modal- </button>- <ng-container slot="body">- <div class="spot-container">- <h1 class="spot-header-small">Test</h1>-- <spot-text-field- placeholder="Placeholder value"- [(ngModel)]="textFieldValue"- >- <span- slot="before"- class="spot-icon spot-icon_bell"- ></span>- </spot-text-field>- </div>- </ng-container>-</spot-drop-modal>--<h1>Tooltip</h1>--<section class="space-children">- <select [(ngModel)]="tooltipAlignment">- <option>left-top</option>- <option>left-center</option>- <option>left-bottom</option>- <option>top-left</option>- <option>top-center</option>- <option>top-right</option>- <option>right-top</option>- <option>right-center</option>- <option>right-bottom</option>- <option>bottom-left</option>- <option>bottom-center</option>- <option>bottom-right</option>- </select>- <spot-tooltip [alignment]="tooltipAlignment">- <ng-container slot="trigger">Trigger</ng-container>- <p- slot="body"- class="spot-body-small"- >Body</p>- </spot-tooltip>-- <spot-tooltip [alignment]="tooltipAlignment">- <ng-container slot="trigger">Trigger</ng-container>- <ng-container slot="body">- <p class="spot-body-small">Body with multiple paragraphs coming in here</p>- <p class="spot-body-small">This is the second paragraph</p>- </ng-container>- </spot-tooltip>-- <spot-tooltip- [alignment]="tooltipAlignment"- [dark]="true"- >- <ng-container slot="trigger">Dark tooltip trigger</ng-container>- <ng-container slot="body">- <p class="spot-body-small">This is a dark tooltip</p>- </ng-container>- </spot-tooltip>-</section>--<h1>Action Bar</h1>--<div class="spot-action-bar">- <div class="spot-action-bar--left">- <button class="spot-button spot-button_outlined spot-button_main spot-action-bar--action">- Independent action- </button>- </div>- <div class="spot-action-bar--right">- <button class="spot-button spot-button_outlined spot-button_main spot-action-bar--action">- Some Action- </button>- <button class="spot-button spot-button_main spot-action-bar--action">- Another Action- </button>- </div>-</div>--<h1>Modals</h1>--<div class="spot-modal">- <div class="spot-modal--header">Default size modal</div>- <div class="spot-modal--body spot-container">- <p class="spot-body-small">Here is some text in the body. Additionally this is a destructive action.</p>- </div>- <div class="spot-action-bar">- <div class="spot-action-bar--right">- <button class="spot-button spot-button_outlined spot-button_main spot-action-bar--action">- Cancel- </button>- <button class="spot-button spot-button_danger spot-action-bar--action">- <span class="spot-icon spot-icon_delete"></span>- <span>Delete</span>- </button>- </div>- </div>-</div>--<div class="spot-modal spot-modal_wide">- <div class="spot-modal--header">- <span class="spot-icon spot-icon_help1"></span>- <span>Wide modal</span>- </div>- <div class="spot-divider"></div>- <div class="spot-modal--body spot-container">- <p class="spot-body-small">Here is some text in the body.</p>- <p class="spot-body-small">But this modal has a minimal height!</p>- </div>- <div class="spot-action-bar">- <div class="spot-action-bar--right">- <span>Some explanatory text.</span>- <button class="spot-button spot-button_main spot-action-bar--action">- OK- </button>- </div>- </div>-</div>--<style>- #content-wrapper {- background-color: #eee;- }-</style>diff --git a/frontend/src/app/spot/spot-docs.component.sass b/frontend/src/app/spot/spot-docs.component.sassdeleted file mode 100644index 86e92a378ae..00000000000--- a/frontend/src/app/spot/spot-docs.component.sass+++ /dev/null@@ -1,11 +0,0 @@-.space-children- display: flex- flex-wrap: wrap-- > *- margin: 0.5rem--// This is done so we can see all-white elements-#content,-#content-wrapper- background-color: #eeediff --git a/frontend/src/app/spot/spot-docs.component.ts b/frontend/src/app/spot/spot-docs.component.tsdeleted file mode 100644index 1b576c95e2c..00000000000--- a/frontend/src/app/spot/spot-docs.component.ts+++ /dev/null@@ -1,64 +0,0 @@-import { Component, ViewEncapsulation } from '@angular/core';-import { FormControl, FormGroup, Validators } from '@angular/forms';--/* eslint-disable-next-line change-detection-strategy/on-push */-@Component({- selector: 'spot-docs',- templateUrl: './spot-docs.component.html',- styleUrls: ['./spot-docs.component.sass'],- encapsulation: ViewEncapsulation.None,-})-export class SpotDocsComponent {- indeterminateState = null;-- checkboxValue = null;-- listCheckboxValue = null;-- textFieldValue = 'ngModel value';-- usernameForm = new FormGroup({- username: new FormControl('', [- /* eslint-disable-next-line @typescript-eslint/unbound-method */- Validators.required,- Validators.minLength(3),- Validators.maxLength(5),- ]),- });-- dropModalOpen = false;-- dropModalAlignment = 'bottom-left';-- tooltipAlignment = 'right-center';-- toggleValue = null;-- toggleOptions = [- { value: 1, title: '1' },- { value: 2, title: '2' },- { value: 3, title: '3' },- ];-- onRemoveChip():void {- /* eslint-disable-next-line no-alert */- alert('Remove chip');- }-- checkboxValueString():string {- if (this.checkboxValue === null) {- return 'null (indeterminate)';- }-- if (this.checkboxValue) {- return 'true (checked)';- }-- return 'false (unchecked)';- }-- onUsernameSubmit():void {- /* eslint-disable-next-line no-alert */- alert(this.usernameForm.get('username')?.value);- }-}diff --git a/frontend/src/app/spot/spot.module.ts b/frontend/src/app/spot/spot.module.tsindex 27ac967a914..3ad0f66b764 100644--- a/frontend/src/app/spot/spot.module.ts+++ b/frontend/src/app/spot/spot.module.ts@@ -4,9 +4,7 @@ import {ReactiveFormsModule,} from '@angular/forms';import { CommonModule } from '@angular/common';-import { UIRouterModule } from '@uirouter/angular';import { I18nService } from 'core-app/core/i18n/i18n.service';-import { SPOT_DOCS_ROUTES } from './spot.routes';import { SpotCheckboxComponent } from './components/checkbox/checkbox.component';import { SpotSwitchComponent } from './components/switch/switch.component';import { SpotToggleComponent } from './components/toggle/toggle.component';@@ -16,14 +14,10 @@ import { SpotDropModalComponent } from './components/drop-modal/drop-modal.compoimport { SpotTooltipComponent } from './components/tooltip/tooltip.component';import { SpotFormFieldComponent } from './components/form-field/form-field.component';import { SpotFormBindingDirective } from './components/form-field/form-binding.directive';-import { SpotDocsComponent } from './spot-docs.component';import { SpotSelectorFieldComponent } from 'core-app/spot/components/selector-field/selector-field.component';-import { AttributeHelpTextModule } from 'core-app/shared/components/attribute-help-texts/attribute-help-text.module';@NgModule({imports: [- // Routes for /spot-docs- UIRouterModule.forChild({ states: SPOT_DOCS_ROUTES }),FormsModule,ReactiveFormsModule,CommonModule,@@ -34,8 +28,6 @@ import { AttributeHelpTextModule } from 'core-app/shared/components/attribute-he],declarations: [- SpotDocsComponent,-SpotCheckboxComponent,SpotSwitchComponent,SpotToggleComponent,diff --git a/frontend/src/app/spot/spot.routes.ts b/frontend/src/app/spot/spot.routes.tsdeleted file mode 100644index e0bbd851f1c..00000000000--- a/frontend/src/app/spot/spot.routes.ts+++ /dev/null@@ -1,41 +0,0 @@-// -- copyright-// OpenProject is an open source project management software.-// Copyright (C) 2012-2022 the OpenProject GmbH-//-// This program is free software; you can redistribute it and/or-// modify it under the terms of the GNU General Public License version 3.-//-// OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows:-// Copyright (C) 2006-2013 Jean-Philippe Lang-// Copyright (C) 2010-2013 the ChiliProject Team-//-// This program is free software; you can redistribute it and/or-// modify it under the terms of the GNU General Public License-// as published by the Free Software Foundation; either version 2-// of the License, or (at your option) any later version.-//-// This program is distributed in the hope that it will be useful,-// but WITHOUT ANY WARRANTY; without even the implied warranty of-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the-// GNU General Public License for more details.-//-// You should have received a copy of the GNU General Public License-// along with this program; if not, write to the Free Software-// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.-//-// See COPYRIGHT and LICENSE files for more details.-//++--import { Ng2StateDeclaration } from '@uirouter/angular';-import { SpotDocsComponent } from './spot-docs.component';--export const SPOT_DOCS_ROUTES:Ng2StateDeclaration[] = [- {- name: 'styleguide',- parent: 'root',- url: '/design/spot',- views: {- '!$default': { component: SpotDocsComponent },- },- },-];