Releases: ZenSoftware/zen
Releases · ZenSoftware/zen
v2.1.0 <zen-layout> release
Issue: #11
- Refactor the current combination of
<mat-toolbar>
andmat-sidenav-container
and abstract it as a<zen-layout>
component instead. - Responsive mobile first design. Reference: Academind - Angular Material Responsive Navigation Tutorial
- Multiple
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>
v2.0.0 Battle tested and hardened the starter kit 🎐
⛩ Major version update ⛩
- All dependencies updated 🎆
- Subscription example released 💻
- Upload example released 💾
- Imitate RBAC rules for ASP.NET Core 🎏
- Nest authorization decorators work with GraphQL queries, mutations, uploads & subscriptions! 💙
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');
}
}
v1.3.0 Replaced GraphQL Playground for Apollo Sandbox
- Replaced GraphQL Playground for Apollo Sandbox
- Included an example of how to upload files via GraphQL
v1.2.1
Increased performance on outgoing HTTP requests
v1.2.0
Replaced cookies for local storage authentication flow. The project no longer has any dependencies on cookies.
v1.1.1
- Authorization overhaul to be in line with ASP.NET Core RBAC rules
- Lots of bug fixes
v1.0.0 Stable release
All dependencies updated to latest versions
- Upgraded to Nx 13
- Upgraded to Angular v12
- Upgraded to Nest v7
- Upgraded to Bootstrap v5
- PostgreSQL v14
v0.3.0 Prisma @angular/forms helpers
@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
v0.2.3 exposed better API configurations through environments
- Exposed CORS and GraphQL Upload configurations through
environment.ts
andenvironment.prod.ts
- Updated 3rd party dependencies
v0.2.2 updated Prisma v2.16.0
z0.2.2 package update