Bot releases are visible (Hide)
Published by ZenSoftware over 2 years ago
Issue: https://github.com/ZenSoftware/zen/issues/11
<mat-toolbar>
and mat-sidenav-container
and abstract it as a <zen-layout>
component instead.ng-content
projections entry points that can be selected via <div slot="...">
as named sections.<!-- app.component.html -->
<zen-layout>
<div slot="menu-content">
...Menu items...
</div>
<div slot="main-content">
<router-outlet></router-outlet>
</div>
</zen-layout>
Published by ZenSoftware over 2 years ago
zen/apps/api/src/app/graphql/resolvers/Sample.ts
export const typeDefs = gql`
extend type Mutation {
sampleUpload(file: Upload!): Boolean!
}
type SampleSubscriptionResult {
message: String!
}
type Subscription {
sampleSubscription: SampleSubscriptionResult!
}
`;
const pubSub = new PubSub();
interval(1000).subscribe(i =>
pubSub.publish('sampleSubscription', {
sampleSubscription: {
message: `Server ticker ${i}`,
},
})
);
@Resolver()
@UseGuards(GqlGuard)
@Roles('Super')
export class SampleResolver {
@Mutation()
async sampleUpload(@Args('file', { type: () => GraphQLUpload }) file: FileInfo) {
const readStream = file.file.createReadStream();
const chunks = [];
for await (const chunk of readStream) {
chunks.push(chunk);
}
const buffer = Buffer.concat(chunks);
Logger.log(`Recieved '${file.file.filename}' ${buffer.byteLength} bytes`);
return true;
}
@Subscription()
async sampleSubscription(@GqlUser() user: RequestUser) {
Logger.log(`sampleSubscription subscribed to by user with id ${user.id}`);
return pubSub.asyncIterator('sampleSubscription');
}
}
Published by ZenSoftware almost 3 years ago
Published by ZenSoftware almost 3 years ago
Increased performance on outgoing HTTP requests
Published by ZenSoftware almost 3 years ago
Replaced cookies for local storage authentication flow. The project no longer has any dependencies on cookies.
Published by ZenSoftware almost 3 years ago
Published by ZenSoftware almost 3 years ago
All dependencies updated to latest versions
Published by ZenSoftware over 3 years ago
@zen/graphql
Prisma helpers released. These really help simplify utilizing @angular/forms
with Prisma.
selectOne(value: any): {id: any}
selectMany(items: any[]): Array<{id: any}>
makeSetObject(data) // Omits `__typename` and `id` properties from an object
makeCreateObject(data) // Makes a Prisma create object from a value object
makeUpdateObject(data) // Makes a Prisma update object from a value object
Published by ZenSoftware over 3 years ago
environment.ts
and environment.prod.ts
Published by ZenSoftware over 3 years ago
Published by ZenSoftware over 3 years ago
All 3rd party dependencies upgraded to latest versions, including:
Published by ZenSoftware over 3 years ago