import { Component, OnInit } from '@angular/core';
import { DescriptiveCardProperties } from '../../interfaces/descriptive-card-properties-interface';
import { DescriptiveCardCSSProperties } from '../../interfaces/descriptive-card-css-properties-interface';

@Component({
  selector: 'app-car-packages',
  templateUrl: './car-packages.component.html',
  styleUrls: ['./car-packages.component.scss']
})
export class CarPackagesComponent implements OnInit {

  public descriptiveCardItem: DescriptiveCardProperties;
  public descriptiveCardCSSItem: DescriptiveCardCSSProperties;

  obj = {
    heading: 'Packages',
    data: [
      {
        image: '../../../assets/images/Seats@2x.png',
        text: `Driver's seat electrically adjustable with memory function.`,
        altText: ''
      },
      {
        image: '../../../assets/images/Ignition Button@2x.png',
        text: `KEYLESS-GO Comfort package.`,
        altText: ''
      },
      {
        image: '../../../assets/images/Door Controls@2x.png',
        text: `Storage Packet.`,
        altText: ''
      }
    ]
  };



  constructor() {

    this.descriptiveCardItem = {
      imageUrl: '../../../../assets/images/car-interior-design.png',
      title: 'Upholstery',
      subtitle: 'Leather Black',
      amount: 2000,
      currency: 'KRW',
      description: "Driver's seat, electrically adjustable with memory function (included in basic price). Lorem ipsum dolor sit amet, consectetur adipiscing elit."
    }
  }

  ngOnInit() {
  }


  public updateDsccp(event: DescriptiveCardCSSProperties) {
    console.log(event);
    this.descriptiveCardCSSItem = event;
  }

}
