#!/bin/bash

# Check if the input file is provided
if [ "$#" -ne 1 ]; then
    echo "Usage: $0 <input-file>"
    exit 1
fi

input_file="$1"


cat << EOF

@Component()
export class ¢{name}ModalComponent extends ModalableComponentAdaptor {
{
    public modelPrototype = ${name}.prototype[MetadataDefinition.METADATA_CONTAINER_PROPERTY_NAME];
    public item: ${name};
    public items: Array<${name}>;

    constructor(private readonly _patientsDuplicationService: PatientsDuplicationService) {
        super();
    }

    public async onBeforeOpen(parameters: ¢{name}ModalParameter): Promise<void> {
    }
}

export class ¢{name}ModalParameter extends ModalParameters {
    public item: ${name};
    public items: Array<${name}>;
}

EOF