I want to achieve something like this:
But I am currently in that stage
Note that, first image is bootstrap form , 2nd image is what I am designing with ionic [ there are some reasons I don't want to drag bootstrap in my ionic project, so, obviously everything will not be 100% perfect in look, but I want to get something closer to it]
My Question is:
- How can I set Item name to vertically center ?
[ see 2nd image, I already tried
justify-content-center
&&align-items-center
] - How can I align text of Item name to Apple (like first image)
[ i tried
class="ion-float-left"
but it seems if i give it or not, in 2nd image, Item name stays the same, also if I put the wholeion-row
(see code) underion-list
, it looks horrible ]
Here is my ionic code
product-list.page.html
<ion-header>
<ion-toolbar color="primary" class="ion-text-center">
<ion-title>Stock</ion-title>
</ion-toolbar>
</ion-header>
<ion-content padding>
<ion-grid>
<ion-row>
<ion-col size-md="6" offset-md="3">
<ion-card>
<ion-card-header>
<ion-card-title>
</ion-card-title>
</ion-card-header>
<ion-card-content>
<ion-row class="background1 justify-content-center align-items-center" style="height: 100%" >
<ion-col>
<ion-text class="ion-float-left" style="font-size: 12px; font-weight: bold; ">Item Name</ion-text>
</ion-col>
<ion-col>
<ion-button (click)=onBackButtonPressed() color="secondary" class="ion-float-right" size="small">
Back
</ion-button>
</ion-col>
</ion-row>
<ion-list *ngIf="currentList">
<ion-item *ngFor="let item of currentList" (click)="setIonList(item)">
{{item}}
</ion-item>
</ion-list>
</ion-card-content>
</ion-card>
</ion-col>
</ion-row>
</ion-grid>
</ion-content>