Compare commits

..

2 Commits

Author SHA1 Message Date
Rainer Killinger
b7f512b7bd refactor: update changelog
ci: publish release
2023-08-03 16:08:02 +02:00
Rainer Killinger
78d9690974 ci: polish publishing via ci pipelines 2023-08-03 16:00:32 +02:00
44 changed files with 468 additions and 612 deletions

View File

@@ -1,5 +0,0 @@
---
'@openstapps/app': patch
---
Use observable chains instead of change detection in the rating component

View File

@@ -1,5 +0,0 @@
---
'@openstapps/app': minor
---
Added the ability to remove and add date series from their detail page

View File

@@ -1,5 +0,0 @@
---
'@openstapps/app': patch
---
Add a way to hide action chips on list items

View File

@@ -1,9 +0,0 @@
---
'@openstapps/app': minor
---
Improved calendar descriptions
- The dashboard quick link now has a more intuitive icon
- "Recurring" has been renamed to "Week Overview"
- Long words in calendar tabs will now break instead of overflowing

View File

@@ -1,13 +0,0 @@
---
'@openstapps/app': minor
---
Revamp "My Courses" section on profile page
The "My Courses" section on the profile page has been improved
- It will now show the upcoming courses for the next five days
- The section header is now consistent with the other sections
- The section now uses standard list items instead of the custom solution
Additionally, the profile page component has been cleaned up.

View File

@@ -1,5 +0,0 @@
---
'@openstapps/app': minor
---
Replaced simple links with list items in date-series detail

View File

@@ -1,5 +0,0 @@
---
'@openstapps/app': minor
---
Use event title for date series instead of the generic date series title

View File

@@ -32,7 +32,7 @@ variables:
default:
image: registry.gitlab.com/openstapps/openstapps/node-builder
tags:
- saas-linux-xlarge-amd64
- performance
interruptible: true
before_script:
- corepack enable

View File

@@ -1,6 +1,6 @@
.limit_publish_pipelines:
rules:
- if: '($CI_COMMIT_BRANCH == "main" || $CI_COMMIT_BRANCH == "develop") && $CI_COMMIT_MESSAGE =~ /ci: publish release/ && $CI_PIPELINE_SOURCE != "schedule"'
- if: '($CI_COMMIT_BRANCH == "main" || $CI_COMMIT_BRANCH == "develop") && $CI_COMMIT_MESSAGE =~ /^ci: publish release/ && $CI_PIPELINE_SOURCE != "schedule"'
deploy:
stage: publish

View File

@@ -18,7 +18,7 @@ base image:
docker build
-t "${CI_REGISTRY_IMAGE}/${IMAGE_NAME}:$(grep -o '"version": "[^"]*' "${DEPLOY_DIR}/package.json" | cut -d'"' -f4)"
-t "${CI_REGISTRY_IMAGE}/${IMAGE_NAME}:latest" "${CI_PROJECT_DIR}/${DEPLOY_DIR}" &&
docker push "${CI_REGISTRY_IMAGE}/${IMAGE_NAME}" --all-tags
docker push "${CI_REGISTRY_IMAGE}/${IMAGE_NAME}"
cache: {} # disable irrelevant cache for this job
before_script: [] # do not run irrelevant before script for this job
parallel:
@@ -29,7 +29,5 @@ base image:
DEPLOY_DIR: images/node-builder
- IMAGE_NAME: app-builder
DEPLOY_DIR: images/app-builder
- IMAGE_NAME: app-cypress
DEPLOY_DIR: images/app-cypress
rules:
- !reference [.limit_scheduled_pipelines, rules]

View File

@@ -1,12 +1,9 @@
e2e:
image: registry.gitlab.com/openstapps/openstapps/app-cypress:node-18
image: cypress/browsers:latest # https://hub.docker.com/r/cypress/browsers/tags/
stage: test
script:
- pnpm --filter=@openstapps/app install
- pnpm --filter=@openstapps/app exec cypress install
- cd node_modules/.pnpm/re2*/node_modules/re2
- npm run install
- cd $CI_PROJECT_DIR
- pnpm test:integration:app
artifacts:
when: on_failure

View File

@@ -42,17 +42,3 @@ The command `ionic cordova run ios` runs into the error `/platforms/ios/build/em
- Either use the command: `ionic cordova emulate ios -- --buildFlag="-UseModernBuildSystem=0"`
- Or open the iOS project in Xcode and change build system in workspace settings to `Lagacy Build System`. Then the normal run command works also.
## Cypress
#### Problem
The browser doesn't open or the tests don't connect to a browser
#### Solution
Delete the Cypress config file
```shell
rm -rf ~/.config/Cypress
```

View File

@@ -18,18 +18,14 @@
describe('dashboard', async function () {
describe('schedule section', function () {
it('should lead to the week overview', function () {
it('should lead to the schedule', function () {
cy.visit('/overview');
cy.get('.schedule')
.contains('a', /Wochen.*übersicht/)
.click();
cy.url().should('include', '/schedule/week-overview');
});
cy.get('.schedule').contains('a', 'Stundenplan').click();
cy.url().should('include', '/schedule/recurring');
it('should lead to the calendar', function () {
cy.visit('/overview');
cy.get('.schedule').contains('a', 'Kein Eintrag gefunden').click();
cy.url().should('include', '/schedule/calendar');
cy.url().should('include', '/schedule/recurring');
});
// TODO: Reenable and stabilize tests

View File

@@ -19,19 +19,19 @@
</ion-toolbar>
</ion-header>
<div #schedule class="schedule">
<a [routerLink]="['/schedule/week-overview']">
<ion-icon size="36" weight="300" name="calendar_month"></ion-icon>
<ion-label [innerHTML]="'schedule.recurring' | translate"></ion-label>
<a [routerLink]="['/schedule/recurring']">
<ion-icon size="40" weight="300" name="grid_view"></ion-icon>
<ion-label>{{ 'schedule.recurring' | translate }}</ion-label>
</a>
<!-- Avoid structural directives here, they might interfere with the collapse animation -->
<a
[routerLink]="nextEvent ? ['/data-detail', nextEvent!.uid] : ['/schedule/calendar']"
[routerLink]="nextEvent?.event ? ['/data-detail', nextEvent!.event.uid] : ['/schedule/recurring']"
class="schedule-item-button"
>
<ion-label>{{ 'dashboard.schedule.title' | translate }}</ion-label>
<ion-label>
{{
nextEvent
nextEvent?.event
? (nextEvent!.dates | nextDateInList | amDateFormat : 'll, HH:mm')
: ('dashboard.schedule.noEvent' | translate)
}}

View File

@@ -117,7 +117,6 @@ ion-content {
ion-label {
font-size: var(--font-size-xxs);
font-weight: var(--font-weight-semi-bold);
word-break: break-word;
}
&:hover ::ng-deep stapps-icon {

View File

@@ -1,4 +1,3 @@
/* eslint-disable unicorn/no-useless-undefined */
/*
* Copyright (C) 2023 StApps
* This program is free software: you can redistribute it and/or modify it
@@ -13,51 +12,60 @@
* You should have received a copy of the GNU General Public License along with
* this program. If not, see <https://www.gnu.org/licenses/>.
*/
import {ChangeDetectionStrategy, Component, ElementRef, HostListener, Input} from '@angular/core';
import {SCDish, SCRatingRequest} from '@openstapps/core';
import {Component, ElementRef, HostListener, Input} from '@angular/core';
import {SCDish, SCRatingRequest, SCUuid} from '@openstapps/core';
import {RatingProvider} from '../rating.provider';
import {ratingAnimation} from './rating.animation';
import {BehaviorSubject, filter, merge, mergeMap, of, ReplaySubject, withLatestFrom} from 'rxjs';
import {catchError, map} from 'rxjs/operators';
@Component({
selector: 'stapps-rating',
templateUrl: 'rating.html',
styleUrls: ['rating.scss'],
animations: [ratingAnimation],
changeDetection: ChangeDetectionStrategy.OnPush,
})
export class StappsRatingComponent {
performRating = new BehaviorSubject(false);
rate = false;
userRating = new BehaviorSubject<number | undefined>(undefined);
rated = false;
dish = new ReplaySubject<SCDish>(1);
canBeRated = false;
wasAlreadyRated = merge(
this.dish.pipe(mergeMap(({uid}) => this.ratingProvider.hasRated(uid))),
this.userRating.pipe(
filter(it => it !== undefined),
withLatestFrom(this.dish),
mergeMap(([rating, {uid}]) => this.ratingProvider.rate(uid, rating as SCRatingRequest['rating'])),
map(() => true),
catchError(() => of(false)),
),
);
uid: SCUuid;
canBeRated = this.dish.pipe(mergeMap(dish => this.ratingProvider.canRate(dish)));
rating?: number;
@Input({required: true}) set item(value: SCDish) {
this.dish.next(value);
@Input() set item(value: SCDish) {
this.uid = value.uid;
Promise.all([this.ratingProvider.canRate(value), this.ratingProvider.hasRated(this.uid)] as const).then(
([canRate, hasRated]) => {
this.canBeRated = canRate;
this.rated = hasRated;
},
);
}
constructor(readonly elementRef: ElementRef, readonly ratingProvider: RatingProvider) {}
async submitRating(rating: number) {
this.rating = rating;
try {
await this.ratingProvider.rate(this.uid, rating as SCRatingRequest['rating']);
this.rated = true;
} catch {
this.rating = undefined;
// allow change detection to catch up first
setTimeout(() => {
this.rate = false;
});
}
}
@HostListener('document:mousedown', ['$event'])
clickOutside(event: MouseEvent) {
if (this.userRating.value) return;
if (this.rating) return;
if (!this.elementRef.nativeElement.contains(event.target)) {
this.performRating.next(false);
this.rate = false;
}
}
}

View File

@@ -14,23 +14,19 @@
-->
<ion-button
*ngIf="canBeRated | async"
*ngIf="canBeRated"
fill="clear"
(click)="$event.stopPropagation(); performRating.next(true)"
[disabled]="wasAlreadyRated | async"
(click)="$event.stopPropagation(); rate = true"
[disabled]="rated"
>
<ion-icon slot="icon-only" color="medium" name="thumbs_up_down"></ion-icon>
</ion-button>
<div
class="rating-stars"
*ngIf="(performRating | async) && (wasAlreadyRated | async) !== true"
[@rating]="(userRating | async) === undefined ? 'abandoned' : 'rated'"
>
<div class="rating-stars" *ngIf="rate && !rated" [@rating]="rating ? 'rated' : 'abandoned'">
<ion-icon
[class.rated-value]="(userRating | async) === i"
[class.rated-value]="rating === i"
*ngFor="let i of [5, 4, 3, 2, 1]"
(click)="$event.stopPropagation(); userRating.next(i)"
(click)="$event.stopPropagation(); submitRating(i)"
slot="icon-only"
size="32"
color="medium"

View File

@@ -38,8 +38,6 @@ export class DataListItemComponent {
@Input() listItemEndInteraction = true;
@Input() listItemChipInteraction = true;
@Input() lines = 'inset';
@Input() forceHeight = false;

View File

@@ -43,7 +43,7 @@
<div>
<ng-template [dataListItemHost]="item"></ng-template>
<stapps-action-chip-list
*ngIf="listItemChipInteraction && appearance !== 'square'"
*ngIf="appearance !== 'square'"
slot="end"
[item]="item"
></stapps-action-chip-list>

View File

@@ -12,49 +12,19 @@
* You should have received a copy of the GNU General Public License along with
* this program. If not, see <https://www.gnu.org/licenses/>.
*/
import {Component, Input, OnInit} from '@angular/core';
import {Component, Input} from '@angular/core';
import {SCDateSeries} from '@openstapps/core';
import {ScheduleProvider, toDateSeriesRelevantData} from '../../../calendar/schedule.provider';
import {Observable} from 'rxjs';
import {map} from 'rxjs/operators';
import {DataRoutingService} from '../../data-routing.service';
import {Router} from '@angular/router';
import {takeUntilDestroyed} from '@angular/core/rxjs-interop';
/**
* TODO
*/
@Component({
selector: 'stapps-date-series-detail-content',
templateUrl: 'date-series-detail-content.html',
styleUrls: ['date-series-detail-content.scss'],
})
export class DateSeriesDetailContentComponent implements OnInit {
export class DateSeriesDetailContentComponent {
/**
* TODO
*/
@Input() item: SCDateSeries;
isInCalendar: Observable<boolean>;
constructor(
readonly scheduleProvider: ScheduleProvider,
dataRoutingService: DataRoutingService,
router: Router,
) {
dataRoutingService
.itemSelectListener()
.pipe(takeUntilDestroyed())
.subscribe(item => {
void router.navigate(['/data-detail', item.uid]);
});
}
ngOnInit() {
this.isInCalendar = this.scheduleProvider.uuids$.pipe(map(it => it.includes(this.item.uid)));
}
addToCalendar() {
const current = this.scheduleProvider.partialEvents$.value;
this.scheduleProvider.partialEvents$.next([...current, toDateSeriesRelevantData(this.item)]);
}
removeFromCalendar() {
const filtered = this.scheduleProvider.partialEvents$.value.filter(it => it.uid !== this.item.uid);
this.scheduleProvider.partialEvents$.next(filtered);
}
}

View File

@@ -12,18 +12,23 @@
~ You should have received a copy of the GNU General Public License along with
~ this program. If not, see <https://www.gnu.org/licenses/>.
-->
<ng-container *ngIf="isInCalendar | async; else add">
<ion-chip outline="true" color="success" (click)="removeFromCalendar()">
<ion-icon name="event_available" fill="true"></ion-icon>
<ion-label>{{'chips.addEvent.addedToEvents' | translate}}</ion-label>
</ion-chip>
</ng-container>
<ng-template #add>
<ion-chip outline="true" color="primary" (click)="addToCalendar()">
<ion-icon name="calendar_today"></ion-icon>
<ion-label>{{'chips.addEvent.addEvent' | translate}}</ion-label>
</ion-chip>
</ng-template>
<ion-card>
<ion-card-header> {{ 'event' | propertyNameTranslate : item | titlecase }} </ion-card-header>
<ion-card-content>
<a [routerLink]="['/data-detail', item.event.uid]">{{ 'name' | thingTranslate : item.event }}</a>
</ion-card-content>
</ion-card>
<ion-card *ngIf="item.inPlace">
<ion-card-header> {{ 'inPlace' | propertyNameTranslate : item | titlecase }} </ion-card-header>
<ion-card-content>
<ion-icon name="pin_drop"> </ion-icon>
<a [routerLink]="['/data-detail', item.inPlace.uid]">{{ 'name' | thingTranslate : item.inPlace }}</a>
<stapps-address-detail
*ngIf="item.inPlace.address"
[address]="item.inPlace.address"
></stapps-address-detail>
</ion-card-content>
</ion-card>
<stapps-simple-card
title="{{ 'duration' | propertyNameTranslate : item | titlecase }}"
[content]="[item.duration | amDuration : 'minutes']"
@@ -51,15 +56,3 @@
[content]="item.performers"
></stapps-simple-card>
<stapps-offers-detail *ngIf="item.offers" [offers]="item.offers"></stapps-offers-detail>
<ion-card>
<ion-card-header> {{ 'event' | propertyNameTranslate : item | titlecase }} </ion-card-header>
<ion-card-content>
<stapps-data-list-item [item]="$any(item.event)"></stapps-data-list-item>
</ion-card-content>
</ion-card>
<ion-card *ngIf="item.inPlace">
<ion-card-header> {{ 'inPlace' | propertyNameTranslate : item | titlecase }} </ion-card-header>
<ion-card-content>
<stapps-data-list-item [item]="$any(item.inPlace)"></stapps-data-list-item>
</ion-card-content>
</ion-card>

View File

@@ -1,6 +0,0 @@
ion-chip {
position: absolute;
z-index: 1;
top: 0;
right: 0;
}

View File

@@ -17,7 +17,7 @@
<ion-row>
<ion-col>
<div class="ion-text-wrap">
<ion-label class="title">{{ 'event.name' | thingTranslate : item }}</ion-label>
<ion-label class="title">{{ 'name' | thingTranslate : item }}</ion-label>
<p>
<ion-icon name="calendar_today"></ion-icon>
<span *ngIf="item.dates[0] && item.dates[item.dates.length - 1]">

View File

@@ -1,70 +0,0 @@
import {ChangeDetectionStrategy, Component, Input} from '@angular/core';
import {mergeMap, ReplaySubject} from 'rxjs';
import {map} from 'rxjs/operators';
import {SCDateSeries, SCISO8601Date} from '@openstapps/core';
import moment from 'moment/moment';
import {ScheduleProvider} from '../../calendar/schedule.provider';
interface MyCoursesTodayInterface {
startTime: string;
endTime: string;
course: SCDateSeries;
}
type MyCoursesGroup = [SCISO8601Date, MyCoursesTodayInterface[]][];
/**
* Groups date series into a list of events happening in the next days
* @param dateSeries the date series to group
* @param visibleDays the number of days ahead to group
*/
function groupDays(dateSeries: SCDateSeries[], visibleDays: number): MyCoursesGroup {
const courses: [SCISO8601Date, MyCoursesTodayInterface[]][] = [];
const dates = Array.from({length: visibleDays}, (_, i) => moment().startOf('day').add(i, 'days'));
for (const day of dates) {
const dayCourses: MyCoursesTodayInterface[] = [];
for (const course of dateSeries) {
for (const date of course.dates) {
if (moment(date).isSame(day, 'day')) {
dayCourses.push({
startTime: moment(date).toISOString(),
endTime: moment(date).add(course.duration).toISOString(),
course,
});
}
}
}
courses.push([day.toISOString(), dayCourses]);
}
return courses;
}
@Component({
selector: 'my-courses',
templateUrl: 'my-courses.html',
styleUrls: ['my-courses.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
})
export class MyCoursesComponent {
/**
* The number of days from today to display
*/
@Input({required: true}) set visibleDays(value: number) {
this.visibleDays$.next(value);
}
readonly visibleDays$ = new ReplaySubject<number>();
myCourses = this.visibleDays$.pipe(
mergeMap(visibleDays =>
this.scheduleProvider.uuids$.pipe(
mergeMap(uuids => this.scheduleProvider.getDateSeries(uuids)),
map(dateSeries => groupDays(dateSeries.dates, visibleDays)),
),
),
);
constructor(private scheduleProvider: ScheduleProvider) {}
}

View File

@@ -1,35 +0,0 @@
<ion-accordion-group *ngIf="myCourses | async as myCourses" [value]="myCourses[0][0]">
<ion-accordion
*ngFor="let myCoursesDay of myCourses"
[value]="myCoursesDay[0]"
[disabled]="myCoursesDay[1].length === 0"
>
<ion-item slot="header">
<!-- TODO: when using date-fns, use https://date-fns.org/v2.30.0/docs/formatRelative -->
<ion-label
>{{ myCoursesDay[0] | amDateFormat: 'dddd, ll' }} - {{ ('profile.courses.' + (myCoursesDay[1].length
=== 0 ? 'NO' : myCoursesDay[1].length === 1 ? 'ONE' : 'MANY' ) + '_EVENT') | translate: {count:
myCoursesDay[1].length} }}</ion-label
>
<ion-icon class="ion-accordion-toggle-icon" name="expand_more"></ion-icon>
</ion-item>
<ion-list class="ion-padding" slot="content">
<ng-container *ngIf="myCoursesDay[1].length === 0">
<div class="no-course">{{ 'profile.courses.no_courses' | translate }}</div>
</ng-container>
<ng-container *ngFor="let myCourse of myCoursesDay[1]">
<ion-item-group>
<ion-item-divider
>{{myCourse.startTime | amDateFormat: 'LT'}} - {{myCourse.endTime | amDateFormat:
'LT'}}</ion-item-divider
>
<stapps-data-list-item
[listItemChipInteraction]="false"
[hideThumbnail]="true"
[item]="myCourse.course"
></stapps-data-list-item>
</ion-item-group>
</ng-container>
</ion-list>
</ion-accordion>
</ion-accordion-group>

View File

@@ -1,9 +0,0 @@
ion-accordion-group {
overflow: hidden;
border-radius: var(--border-radius-default);
}
ion-item-divider {
--background: transparent;
--color: inherit;
}

View File

@@ -12,20 +12,41 @@
* You should have received a copy of the GNU General Public License along with
* this program. If not, see <https://www.gnu.org/licenses/>.
*/
import {Component} from '@angular/core';
import {Component, OnInit} from '@angular/core';
import {firstValueFrom, Observable, of, Subscription} from 'rxjs';
import {AuthHelperService} from '../../auth/auth-helper.service';
import {SCAuthorizationProviderType, SCUserConfiguration} from '@openstapps/core';
import {SCAuthorizationProviderType, SCDateSeries, SCUserConfiguration} from '@openstapps/core';
import {ActivatedRoute} from '@angular/router';
import {ScheduleProvider} from '../../calendar/schedule.provider';
import moment from 'moment';
import {SCIcon} from '../../../util/ion-icon/icon';
import {profilePageSections} from '../../../../config/profile-page-sections';
import {filter, map} from 'rxjs/operators';
const CourseCard = {
collapsed: SCIcon`expand_more`,
expanded: SCIcon`expand_less`,
};
interface MyCoursesTodayInterface {
startTime: string;
endTime: string;
course: SCDateSeries;
}
@Component({
selector: 'app-home',
templateUrl: 'profile-page.html',
styleUrls: ['profile-page.scss'],
})
export class ProfilePageComponent {
export class ProfilePageComponent implements OnInit {
data: {
[key in SCAuthorizationProviderType]: {loggedIn$: Observable<boolean>};
} = {
default: {loggedIn$: of(false)},
paia: {loggedIn$: of(false)},
};
user$ = this.authHelper.getProvider('default').user$.pipe(
filter(user => user !== undefined),
map(userInfo => {
@@ -37,18 +58,59 @@ export class ProfilePageComponent {
logins: SCAuthorizationProviderType[] = [];
originPath: string | null;
userInfo?: SCUserConfiguration;
courseCardEnum = CourseCard;
courseCardState = CourseCard.expanded;
todayDate = moment().startOf('day').add(0, 'day').format(); // moment().startOf('day').format(); '2022-05-03T00:00:00+02:00'
myCoursesToday: MyCoursesTodayInterface[] = [];
subscriptions: Subscription[] = [];
constructor(
readonly authHelper: AuthHelperService,
readonly activatedRoute: ActivatedRoute,
readonly scheduleProvider: ScheduleProvider,
private authHelper: AuthHelperService,
private route: ActivatedRoute,
protected readonly scheduleProvider: ScheduleProvider,
) {}
ngOnInit() {
this.data.default.loggedIn$ = this.authHelper.getProvider('default').isAuthenticated$;
this.data.paia.loggedIn$ = this.authHelper.getProvider('paia').isAuthenticated$;
this.subscriptions.push(
this.route.queryParamMap.subscribe(queryParameters => {
this.originPath = queryParameters.get('origin_path');
}),
);
this.getMyCourses();
}
async getMyCourses() {
const result = await firstValueFrom(this.scheduleProvider.uuids$);
const courses = await this.scheduleProvider.getDateSeries(result);
for (const course of courses.dates) {
for (const date of course.dates) {
if (moment(date).startOf('day').format() === this.todayDate) {
this.myCoursesToday[this.myCoursesToday.length] = {
startTime: moment(date).format('LT'),
endTime: moment(date).add(course.duration).format('LT'),
course,
};
}
}
}
}
async signIn(providerType: SCAuthorizationProviderType) {
const originPath = this.activatedRoute.snapshot.queryParamMap.get('origin_path');
await (originPath ? this.authHelper.setOriginPath(originPath) : this.authHelper.deleteOriginPath());
await this.authHelper.getProvider(providerType).signIn();
await this.handleOriginPath();
this.authHelper.getProvider(providerType).signIn();
}
async signOut(providerType: SCAuthorizationProviderType) {
@@ -56,6 +118,25 @@ export class ProfilePageComponent {
this.userInfo = undefined;
}
toggleCourseCardState() {
if (this.courseCardState === CourseCard.expanded) {
const card: HTMLElement | null = document.querySelector('.course-card');
const height = card?.scrollHeight;
if (card && height) {
card.style.setProperty('--max-height', height + 'px');
}
}
this.courseCardState =
this.courseCardState === CourseCard.expanded ? CourseCard.collapsed : CourseCard.expanded;
}
private async handleOriginPath() {
this.originPath
? await this.authHelper.setOriginPath(this.originPath)
: await this.authHelper.deleteOriginPath();
}
ionViewWillEnter() {
this.authHelper
.getProvider('default')

View File

@@ -23,53 +23,76 @@
</ion-header>
<ion-content color="light" parallax [parallaxSize]="130">
<ion-card class="user-card">
<ion-card-header>
<ion-img src="assets/imgs/header.svg"></ion-img>
<span *ngIf="user$ | async as userInfo">
{{ userInfo.role ? (userInfo?.role | titlecase) : ('profile.role_guest' | translate | titlecase) }}
</span>
</ion-card-header>
<ion-card-content>
<ion-img class="profile-card-img" src="assets/imgs/profile-card-head.svg"></ion-img>
<ion-grid>
<ion-row>
<ion-col size="3"></ion-col>
<ion-col
*ngIf="authHelper.getProvider('default').isAuthenticated$ | async as loggedIn; else logInPrompt"
size="9"
class="main-info"
>
<ng-container *ngIf="user$ | async as userInfo">
<ion-text class="full-name"> {{ userInfo?.name }} </ion-text>
<div class="matriculation-number">
<ion-label> {{ 'profile.userInfo.studentId' | translate | uppercase }} </ion-label>
<ion-text> {{ userInfo?.studentId }} </ion-text>
</div>
<div class="user-name">
<ion-label> {{ 'profile.userInfo.username' | translate | uppercase }} </ion-label>
<ion-text>{{ userInfo?.id }}</ion-text>
</div>
<div class="email">
<ion-label> {{ 'profile.userInfo.email' | translate | uppercase }} </ion-label>
<ion-text> {{ userInfo?.email }} </ion-text>
</div>
</ng-container>
</ion-col>
<ng-template #logInPrompt>
<ion-col size="9">
<ion-text class="log-in-prompt"> {{ 'profile.userInfo.logInPrompt' | translate }} </ion-text>
<section class="user-card-wrapper">
<ion-card class="user-card">
<ion-card-header>
<ion-img src="assets/imgs/header.svg"></ion-img>
<span *ngIf="user$ | async as userInfo">
{{ userInfo.role ? (userInfo?.role | titlecase) : ('profile.role_guest' | translate | titlecase) }}
</span>
</ion-card-header>
<ion-card-content>
<ion-img class="profile-card-img" src="assets/imgs/profile-card-head.svg"></ion-img>
<ion-grid>
<ion-row>
<ion-col size="3"></ion-col>
<ion-col
*ngIf="data.default.loggedIn$ | async as loggedIn; else logInPrompt"
size="9"
class="main-info"
>
<ng-container *ngIf="user$ | async as userInfo">
<ion-text class="full-name"> {{ userInfo?.name }} </ion-text>
<div class="matriculation-number">
<ion-label> {{ 'profile.userInfo.studentId' | translate | uppercase }} </ion-label>
<ion-text> {{ userInfo?.studentId }} </ion-text>
</div>
<div class="user-name">
<ion-label> {{ 'profile.userInfo.username' | translate | uppercase }} </ion-label>
<ion-text>{{ userInfo?.id }}</ion-text>
</div>
<div class="email">
<ion-label> {{ 'profile.userInfo.email' | translate | uppercase }} </ion-label>
<ion-text> {{ userInfo?.email }} </ion-text>
</div>
</ng-container>
</ion-col>
</ng-template>
</ion-row>
</ion-grid>
</ion-card-content>
</ion-card>
<ng-template #logInPrompt>
<ion-col size="9">
<ion-text class="log-in-prompt"> {{ 'profile.userInfo.logInPrompt' | translate }} </ion-text>
</ion-col>
</ng-template>
</ion-row>
</ion-grid>
</ion-card-content>
</ion-card>
</section>
<stapps-profile-page-section
*ngFor="let section of sections"
[item]="section"
></stapps-profile-page-section>
<stapps-section [title]="'profile.titleCourses' | translate">
<my-courses [visibleDays]="5"></my-courses>
</stapps-section>
<section class="courses">
<ion-label class="section-headline"> {{ 'profile.titleCourses' | translate | uppercase }} </ion-label>
<ion-card class="courses-card">
<ion-card-header (click)="toggleCourseCardState()">
<span>{{ 'profile.courses.today' | translate | uppercase }}</span>
<ion-icon [name]="courseCardState" color="dark" size="20"></ion-icon>
</ion-card-header>
<ion-card-content class="course-card" [class.show-card]="courseCardState === courseCardEnum.expanded">
<ng-container *ngIf="myCoursesToday.length === 0">
<div class="no-course">{{ 'profile.courses.no_courses' | translate }}</div>
</ng-container>
<ng-container *ngFor="let myCourse of myCoursesToday">
<div class="clickable" [routerLink]="['/data-detail', myCourse.course.event.uid]">
<div>{{ myCourse?.startTime }} - {{ myCourse?.endTime }}</div>
<div>{{ myCourse?.course.event?.originalCategory }}</div>
<div [class.last]="!myCourse?.course.inPlace?.name">{{ myCourse.course?.event?.name }}</div>
<div *ngIf="myCourse.course?.inPlace?.name" [class.last]="myCourse.course?.inPlace?.name">
{{ myCourse.course?.inPlace.name }}
</div>
</div>
</ng-container>
</ion-card-content>
</ion-card>
</section>
</ion-content>

View File

@@ -12,106 +12,216 @@
* You should have received a copy of the GNU General Public License along with
* this program. If not, see <https://www.gnu.org/licenses/>.
*/
// TODO: clean up this mess
.user-card {
position: relative;
:host {
section {
margin-bottom: calc(2 * var(--spacing-lg) - var(--spacing-md));
padding: var(--spacing-md);
max-width: 400px;
margin: var(--spacing-xl);
border-radius: var(--border-radius-default);
box-shadow: var(--shadow-profile-card);
ion-card-header {
--background: var(--ion-color-tertiary);
display: flex;
align-items: center;
padding-top: var(--spacing-sm);
padding-bottom: var(--spacing-sm);
ion-img {
display: block;
height: 36px;
margin-right: auto;
object-position: left 50%;
}
span {
padding-top: 3px;
font-size: var(--font-size-lg);
font-weight: var(--font-weight-bold);
line-height: 1;
color: var(--ion-color-light);
&:last-of-type {
margin-bottom: 0;
}
}
ion-card-content {
min-height: 15vh;
.section-headline {
margin-bottom: var(--spacing-md);
}
.profile-card-img {
position: absolute;
.user-card-wrapper {
margin-bottom: 0;
width: 50%;
.user-card {
position: relative;
max-width: 400px;
margin: 0;
border-radius: var(--border-radius-default);
box-shadow: var(--shadow-profile-card);
ion-card-header {
--background: var(--ion-color-tertiary);
display: flex;
align-items: center;
padding-top: var(--spacing-sm);
padding-bottom: var(--spacing-sm);
ion-img {
display: block;
height: 36px;
margin-right: auto;
object-position: left 50%;
}
span {
padding-top: 3px;
font-size: var(--font-size-lg);
font-weight: var(--font-weight-bold);
line-height: 1;
color: var(--ion-color-light);
}
}
ion-card-content {
min-height: 15vh;
.profile-card-img {
position: absolute;
width: 50%;
height: 100%;
margin-left: calc(var(--spacing-md) * -4);
opacity: 0.13;
object-position: left bottom;
}
.main-info {
display: grid;
grid-template-areas:
'fullName fullName'
'matriculationNumber userName'
'email email';
ion-label {
display: block;
font-size: var(--font-size-sm);
font-weight: var(--font-weight-bold);
color: var(--ion-color-medium-shade);
}
ion-text {
display: block;
font-size: var(--font-size-md);
font-weight: var(--font-weight-bold);
color: var(--ion-color-text);
}
.full-name {
display: block;
grid-area: fullName;
margin-bottom: var(--spacing-sm);
font-size: var(--font-size-lg);
font-weight: var(--font-weight-bold);
}
.matriculation-number {
grid-area: matriculationNumber;
margin-bottom: var(--spacing-sm);
}
.user-name {
grid-area: userName;
margin-bottom: var(--spacing-sm);
}
.email {
grid-area: email;
}
}
.log-in-prompt {
margin: auto 0;
font-size: var(--font-size-lg);
font-weight: var(--font-weight-semi-bold);
color: var(--ion-color-text);
}
}
}
}
ion-thumbnail {
align-items: center;
width: 80%;
height: 80%;
margin: 0;
padding: 10px;
background: var(--placeholder-gray);
border-radius: var(--border-radius-default);
ion-icon {
display: block;
width: 100%;
height: 100%;
margin-left: calc(var(--spacing-md) * -4);
opacity: 0.13;
object-position: left bottom;
color: white;
}
}
.main-info {
display: grid;
grid-template-areas:
'fullName fullName'
'matriculationNumber userName'
'email email';
ion-row.main-info {
margin-bottom: 2px;
font-weight: bold;
}
ion-label {
display: block;
font-size: var(--font-size-sm);
font-weight: var(--font-weight-bold);
color: var(--ion-color-medium-shade);
.courses {
.courses-card {
max-width: 800px;
margin: 0;
background-color: unset;
border-radius: var(--border-radius-default) var(--border-radius-default) 0 0;
box-shadow: none;
ion-card-header {
display: flex;
align-items: center;
justify-content: space-between;
background-color: var(--ion-item-background);
border-radius: var(--border-radius-default) var(--border-radius-default) 0 0;
span {
font-size: var(--font-size-lg);
font-weight: var(--font-weight-bold);
color: var(--ion-item-background-color-contrast);
}
ion-icon {
cursor: pointer;
color: var(--ion-color-light);
}
}
ion-text {
display: block;
font-size: var(--font-size-md);
font-weight: var(--font-weight-bold);
color: var(--ion-color-text);
ion-card-content {
overflow: hidden;
max-height: 0;
margin: 0;
padding: 0;
background-color: var(--ion-item-background);
border-radius: var(--border-radius-default);
transition: max-height 250ms ease-in-out, padding 250ms ease-in-out, margin 250ms ease-in-out;
&.show-card {
display: block;
height: 100%;
max-height: var(--max-height);
margin: var(--spacing-xxl);
padding: var(--spacing-md);
}
div {
font-size: var(--font-size-md);
font-weight: var(--font-weight-black);
color: var(--ion-item-background-color-contrast);
text-align: center;
&.no-course {
padding: var(--spacing-xxl) var(--spacing-lg);
}
&.last {
margin-bottom: var(--spacing-xl);
}
}
}
.full-name {
display: block;
grid-area: fullName;
margin-bottom: var(--spacing-sm);
font-size: var(--font-size-lg);
font-weight: var(--font-weight-bold);
}
.matriculation-number {
grid-area: matriculationNumber;
margin-bottom: var(--spacing-sm);
}
.user-name {
grid-area: userName;
margin-bottom: var(--spacing-sm);
}
.email {
grid-area: email;
}
}
.log-in-prompt {
margin: auto 0;
font-size: var(--font-size-lg);
font-weight: var(--font-weight-semi-bold);
color: var(--ion-color-text);
}
}
}

View File

@@ -12,6 +12,7 @@
* You should have received a copy of the GNU General Public License along with
* this program. If not, see <https://www.gnu.org/licenses/>.
*/
import {NgModule} from '@angular/core';
import {CommonModule} from '@angular/common';
import {FormsModule} from '@angular/forms';
@@ -24,9 +25,6 @@ import {UtilModule} from '../../util/util.module';
import {IonIconModule} from '../../util/ion-icon/ion-icon.module';
import {ProfilePageSectionComponent} from './page/profile-page-section.component';
import {ThingTranslateModule} from '../../translation/thing-translate.module';
import {DataModule} from '../data/data.module';
import {MyCoursesComponent} from './page/my-courses.component';
import {MomentModule} from 'ngx-moment';
const routes: Routes = [
{
@@ -36,7 +34,7 @@ const routes: Routes = [
];
@NgModule({
declarations: [MyCoursesComponent, ProfilePageComponent, ProfilePageSectionComponent],
declarations: [ProfilePageComponent, ProfilePageSectionComponent],
imports: [
CommonModule,
FormsModule,
@@ -47,8 +45,6 @@ const routes: Routes = [
SwiperModule,
UtilModule,
ThingTranslateModule,
DataModule,
MomentModule,
],
})
export class ProfilePageModule {}

View File

@@ -136,7 +136,7 @@ export class SchedulePageComponent implements OnInit, AfterViewInit {
onInit() {
this.tabChoreographer = new SharedAxisChoreographer(this.activatedRoute.snapshot.paramMap.get('mode'), [
'calendar',
'week-overview',
'recurring',
'single',
]);
}

View File

@@ -18,18 +18,15 @@
<ion-buttons slot="start">
<ion-back-button></ion-back-button>
</ion-buttons>
<ion-title
*ngIf="tabChoreographer.currentValue === 'calendar'"
[innerHTML]="'schedule.calendar' | translate | titlecase"
></ion-title>
<ion-title
*ngIf="tabChoreographer.currentValue === 'week-overview'"
[innerHTML]="'schedule.recurring' | translate | titlecase"
></ion-title>
<ion-title
*ngIf="tabChoreographer.currentValue === 'single'"
[innerHTML]="'schedule.single' | translate | titlecase"
></ion-title>
<ion-title *ngIf="tabChoreographer.currentValue === 'calendar'"
>{{ 'schedule.calendar' | translate | titlecase }}</ion-title
>
<ion-title *ngIf="tabChoreographer.currentValue === 'recurring'"
>{{ 'schedule.recurring' | translate | titlecase }}</ion-title
>
<ion-title *ngIf="tabChoreographer.currentValue === 'single'"
>{{ 'schedule.single' | translate | titlecase }}</ion-title
>
<ion-buttons slot="end">
<ion-button (click)="onTodayClick()">
<ion-icon name="today" slot="icon-only"></ion-icon>
@@ -39,15 +36,15 @@
<ion-toolbar color="primary" mode="md" class="tabs-toolbar">
<ion-segment #segment value="calendar" (ionChange)="onSegmentChange()">
<ion-segment-button value="calendar" layout="icon-start">
<ion-label class="ion-text-wrap" [innerHTML]="'schedule.calendar' | translate"></ion-label>
<ion-label>{{ 'schedule.calendar' | translate }}</ion-label>
<ion-icon name="calendar_today"></ion-icon>
</ion-segment-button>
<ion-segment-button value="week-overview" layout="icon-start">
<ion-label class="ion-text-wrap" [innerHTML]="'schedule.recurring' | translate"></ion-label>
<ion-segment-button value="recurring" layout="icon-start">
<ion-label>{{ 'schedule.recurring' | translate }}</ion-label>
<ion-icon name="event_repeat"></ion-icon>
</ion-segment-button>
<ion-segment-button value="single" layout="icon-start">
<ion-label class="ion-text-wrap" [innerHTML]="'schedule.single' | translate"></ion-label>
<ion-label>{{ 'schedule.single' | translate }}</ion-label>
<ion-icon name="event_upcoming"></ion-icon>
</ion-segment-button>
</ion-segment>
@@ -62,7 +59,7 @@
>
<stapps-calendar-view *ngSwitchCase="'calendar'" [layout]="layout"></stapps-calendar-view>
<!-- Schedule view needs full week -->
<stapps-schedule-view *ngSwitchCase="'week-overview'" [layout]="layout"></stapps-schedule-view>
<stapps-schedule-view *ngSwitchCase="'recurring'" [layout]="layout"></stapps-schedule-view>
<stapps-single-events *ngSwitchCase="'single'"></stapps-single-events>
</div>

View File

@@ -41,7 +41,7 @@ import {ChooseEventsPageComponent} from './page/choose-events-page.component';
const settingsRoutes: Routes = [
{path: 'schedule', redirectTo: 'schedule/calendar/now'},
{path: 'schedule/calendar', redirectTo: 'schedule/calendar/now'},
{path: 'schedule/week-overview', redirectTo: 'schedule/week-overview/now'},
{path: 'schedule/recurring', redirectTo: 'schedule/recurring/now'},
{path: 'schedule/single', redirectTo: 'schedule/single/now'},
// calendar | recurring | single
{path: 'schedule/:mode/:date', component: SchedulePageComponent},

View File

@@ -459,9 +459,9 @@
"view": {
"today": "Heute"
},
"recurring": "Wochen&shy;übersicht",
"recurring": "Stundenplan",
"calendar": "Kalender",
"single": "Einzel&shy;termine",
"single": "Einzeltermine",
"addEventPage": {
"TITLE": "Termine Hinzufügen",
"PLACEHOLDER": "Termine",
@@ -501,10 +501,8 @@
"logInPrompt": "Bitte loggen Sie sich ein, um Ihre Nutzerdaten sehen zu können."
},
"courses": {
"no_courses": "Heute stehen keine Termine mehr an.",
"NO_EVENT": "Keine Termine",
"ONE_EVENT": "Ein Termin",
"MANY_EVENT": "{{count}} Termine"
"today": "Heute",
"no_courses": "Heute stehen keine Termine mehr an."
}
},
"settings": {

View File

@@ -459,7 +459,7 @@
"view": {
"today": "Today"
},
"recurring": "Week Overview",
"recurring": "Recurring",
"calendar": "Calendar",
"single": "Single Events",
"addEventPage": {
@@ -501,10 +501,8 @@
"logInPrompt": "Please log in to view your user data."
},
"courses": {
"no_courses": "There are no more appointments scheduled today.",
"NO_EVENT": "no events",
"ONE_EVENT": "one event",
"MANY_EVENT": "{{count}} events"
"today": "Today",
"no_courses": "There are no more appointments scheduled today."
}
},
"settings": {

View File

@@ -1,103 +0,0 @@
### Set base image
FROM cypress/base:18.16.1
USER root
RUN node --version
# Install dependencies
RUN apt-get update && \
apt-get install -y \
fonts-liberation \
git \
libcurl4 \
libcurl3-gnutls \
libcurl3-nss \
xdg-utils \
wget \
curl \
# firefox dependencies
bzip2 \
firefox-esr \
# add codecs needed for video playback in firefox
# https://github.com/cypress-io/cypress-docker-images/issues/150
mplayer \
# edge dependencies
gnupg \
dirmngr \
# ci dependencies
build-essential \
jq \
musl-dev \
# clean up
&& rm -rf /var/lib/apt/lists/* \
&& apt-get clean
#funky alpine linux compatibility
RUN ln -s /usr/lib/x86_64-linux-musl/libc.so /lib/libc.musl-x86_64.so.1
# install libappindicator3-1 - not included with Debian 11
RUN wget --no-verbose -O /usr/src/libappindicator3-1_0.4.92-7_amd64.deb "http://ftp.us.debian.org/debian/pool/main/liba/libappindicator/libappindicator3-1_0.4.92-7_amd64.deb" && \
dpkg -i /usr/src/libappindicator3-1_0.4.92-7_amd64.deb ; \
apt update && \
apt --fix-broken install -y && \
rm -rf /var/lib/apt/lists/* && \
apt-get clean && \
rm -f /usr/src/libappindicator3-1_0.4.92-7_amd64.deb
# install Chrome browser
RUN export CHROME_VERSION=$(curl -fsSL https://versionhistory.googleapis.com/v1/chrome/platforms/linux/channels/stable/versions | jq -r '.versions[0].version') && \
wget --no-verbose -O /usr/src/google-chrome-stable_current_amd64.deb "http://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_${CHROME_VERSION}-1_amd64.deb" && \
dpkg -i /usr/src/google-chrome-stable_current_amd64.deb ; \
apt update && \
apt --fix-broken install -y && \
rm -rf /var/lib/apt/lists/* && \
apt-get clean && \
rm -f /usr/src/google-chrome-stable_current_amd64.deb
# "fake" dbus address to prevent errors
# https://github.com/SeleniumHQ/docker-selenium/issues/87
ENV DBUS_SESSION_BUS_ADDRESS=/dev/null
# install Firefox browser
RUN export FIREFOX_VERSION=$(curl -fsSL https://product-details.mozilla.org/1.0/firefox_versions.json | jq -r '.LATEST_FIREFOX_VERSION') && \
wget --no-verbose -O /tmp/firefox.tar.bz2 "https://download-installer.cdn.mozilla.net/pub/firefox/releases/${FIREFOX_VERSION}/linux-x86_64/en-US/firefox-${FIREFOX_VERSION}.tar.bz2" && \
tar -C /opt -xjf /tmp/firefox.tar.bz2 && \
rm /tmp/firefox.tar.bz2 && \
ln -fs /opt/firefox/firefox /usr/bin/firefox
RUN echo "Downloading Latest Edge version..."
## Setup Edge
RUN curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg
RUN install -o root -g root -m 644 microsoft.gpg /etc/apt/trusted.gpg.d/
RUN sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/edge stable main" > /etc/apt/sources.list.d/microsoft-edge-dev.list'
RUN rm microsoft.gpg
## Install Edge
RUN apt-get update && \
apt-get install -y microsoft-edge-dev \
&& rm -rf /var/lib/apt/lists/* \
&& apt-get clean
# Add a link to the browser that allows Cypress to find it
RUN ln -s /usr/bin/microsoft-edge /usr/bin/edge
# versions of local tools
RUN echo " node version: $(node -v) \n" \
"npm version: $(npm -v) \n" \
"yarn version: $(yarn -v) \n" \
"debian version: $(cat /etc/debian_version) \n" \
"Chrome version: $(google-chrome --version) \n" \
"Firefox version: $(firefox --version) \n" \
"Edge version: $(edge --version) \n" \
"git version: $(git --version) \n" \
"whoami: $(whoami) \n"
# a few environment variables to make NPM installs easier
# good colors for most applications
ENV TERM=xterm
# avoid million NPM install messages
ENV npm_config_loglevel=warn
# allow installing when the main user is root
ENV npm_config_unsafe_perm=true

View File

@@ -1,14 +0,0 @@
{
"name": "@openstapps/app-cypress",
"version": "node-18",
"private": true,
"type": "module",
"license": "GPL-3.0-only",
"author": "Rainer Killinger <mail-openstapps@killinger.co>",
"contributors": [
],
"files": [
"Dockerfile",
"CHANGELOG.md"
]
}

View File

@@ -17,7 +17,7 @@
"format:fix": "dotenv -c -- turbo run format:fix",
"lint": "dotenv -c -- turbo run lint",
"lint:fix": "dotenv -c -- turbo run lint:fix",
"publish-packages": "pnpm changeset version && pnpm syncpack:fix && pnpm install && git add . && git commit -m \"docs: update changelogs for release\n\nci: publish release\" && git push && pnpm changeset tag && git push --follow-tags",
"publish-packages": "pnpm changeset version && pnpm syncpack:fix && pnpm install && git add . && git commit -m \"refactor: update changelog\n\nci: publish release\" && git push && pnpm changeset tag && git push --follow-tags",
"syncpack": "syncpack list-mismatches && syncpack lint-semver-ranges --types dev,peer,prod",
"syncpack:fix": "syncpack format && syncpack fix-mismatches",
"test": "trap 'node coverage.mjs' EXIT && dotenv -c -- turbo run test",

View File

@@ -4,9 +4,8 @@
<title>OpenStApps API</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="preconnect" href="https://fonts.bunny.net" />
<link
href="https://fonts.bunny.net/css?family=montserrat:300,400,700|roboto:300,400,700"
href="https://fonts.googleapis.com/css?family=Montserrat:300,400,700|Roboto:300,400,700"
rel="stylesheet"
/>
<!-- Redoc doesn't change outer page styles -->
@@ -18,7 +17,7 @@
</style>
</head>
<body>
<redoc spec-url="./openapi.json"></redoc>
<redoc spec-url="openapi.json"></redoc>
<script src="https://cdn.redoc.ly/redoc/latest/bundles/redoc.standalone.js"></script>
</body>
</html>

View File

@@ -15,7 +15,6 @@
*/
import {EasyAstSpecType} from '../easy-ast-spec-type.js';
import {LightweightDefinitionKind} from '../../src/index.js';
import {TypeFlags} from 'typescript';
// @ts-expect-error unused type
type TestTypeAlias = number | string;
@@ -57,12 +56,12 @@ export const testConfig: EasyAstSpecType = {
{
referenceName: 'Foo',
value: 0,
flags: 1280 as TypeFlags,
flags: 1280,
},
{
referenceName: 'Bar',
value: 1,
flags: 1280 as TypeFlags,
flags: 1280,
},
],
},

View File

@@ -15,7 +15,6 @@
*/
import {EasyAstSpecType} from '../easy-ast-spec-type.js';
import {LightweightDefinitionKind} from '../../src/index.js';
import {TypeFlags} from 'typescript';
// @ts-expect-error unused type
enum TestAuto {
@@ -42,12 +41,12 @@ export const testConfig: EasyAstSpecType = {
{
referenceName: 'Foo',
value: 0,
flags: 1280 as TypeFlags,
flags: 1280,
},
{
referenceName: 'Bar',
value: 1,
flags: 1280 as TypeFlags,
flags: 1280,
},
],
},
@@ -62,12 +61,12 @@ export const testConfig: EasyAstSpecType = {
{
referenceName: 'YES',
value: 'yes',
flags: 1152 as TypeFlags,
flags: 1152,
},
{
referenceName: 'NO',
value: 'no',
flags: 1152 as TypeFlags,
flags: 1152,
},
],
},

View File

@@ -15,7 +15,6 @@
*/
import {EasyAstSpecType} from '../easy-ast-spec-type.js';
import {LightweightDefinitionKind} from '../../src/index.js';
import {TypeFlags} from 'typescript';
// @ts-expect-error unused
interface Test {
@@ -54,7 +53,7 @@ export const testConfig: EasyAstSpecType = {
name: 'boolean_type',
type: {
value: 'boolean',
flags: 1_048_592 as TypeFlags,
flags: 1_048_592,
specificationTypes: [
{
value: 'false',

View File

@@ -3,7 +3,7 @@
"entryPoints": ["packages/**/docs/docs.json"],
"out": "./docs",
"navigationLinks": {
"API": "./api/",
"API": "api",
"GitLab": "https://gitlab.com/openstapps/openstapps/",
"Wiki": "https://gitlab.com/openstapps/openstapps/-/wikis/home"
},