Subbu1304 commited on
Commit
a817aa5
·
verified ·
1 Parent(s): 7c7c418

Update templates/menu.html

Browse files
Files changed (1) hide show
  1. templates/menu.html +97 -1
templates/menu.html CHANGED
@@ -19,6 +19,70 @@
19
  .container {
20
  max-width: 900px;
21
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
22
  /* .menu-card {
23
  max-width: 350px;
24
  border-radius: 15px;
@@ -559,7 +623,7 @@ form-check-input addon-option{
559
  <!-- Menu Sections -->
560
  {% for section, items in ordered_menu.items() %}
561
  <h3>{{ section }}</h3>
562
- <div class="row">
563
  {% for item in items %}
564
  <!-- <div class="col-md-4 mb-4">
565
  <div class="card menu-card">
@@ -606,7 +670,39 @@ form-check-input addon-option{
606
 
607
 
608
  {% endfor %}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
609
  </div>
 
 
 
 
 
610
  {% endfor %}
611
  </div>
612
  {% endif %}
 
19
  .container {
20
  max-width: 900px;
21
  }
22
+
23
+ /* bobby */
24
+
25
+ .menu-card {
26
+ max-width: 100%;
27
+ border-radius: 15px;
28
+ overflow: hidden;
29
+ background-color: #fff;
30
+ position: relative;
31
+ }
32
+
33
+ .menu-image {
34
+ height: 200px;
35
+ width: 100%;
36
+ object-fit: cover; /* Ensures the image covers the area */
37
+ border-radius: 15px 15px 0 0;
38
+ }
39
+
40
+ .customize-btn {
41
+ position: absolute;
42
+ top: 10px; /* Adjust top position */
43
+ left: 10px; /* Adjust left position */
44
+ background-color: rgba(0, 0, 0, 0.5); /* Slight transparent background */
45
+ color: #fff;
46
+ padding: 8px 12px;
47
+ border-radius: 5px;
48
+ border: none;
49
+ font-size: 14px;
50
+ }
51
+
52
+ .card-body {
53
+ padding: 15px;
54
+ }
55
+
56
+ .card-title {
57
+ font-size: 16px;
58
+ font-weight: bold;
59
+ }
60
+
61
+ .card-text {
62
+ font-size: 14px;
63
+ }
64
+
65
+ .btn-danger {
66
+ width: 100%; /* Ensure the 'Add' button takes full width */
67
+ }
68
+
69
+ .d-flex {
70
+ display: flex;
71
+ }
72
+
73
+ .justify-content-between {
74
+ justify-content: space-between;
75
+ }
76
+
77
+ .align-items-center {
78
+ align-items: center;
79
+ }
80
+
81
+
82
+
83
+ /* bobby */
84
+
85
+
86
  /* .menu-card {
87
  max-width: 350px;
88
  border-radius: 15px;
 
623
  <!-- Menu Sections -->
624
  {% for section, items in ordered_menu.items() %}
625
  <h3>{{ section }}</h3>
626
+ <!-- <div class="row">
627
  {% for item in items %}
628
  <!-- <div class="col-md-4 mb-4">
629
  <div class="card menu-card">
 
670
 
671
 
672
  {% endfor %}
673
+ </div> -->
674
+ <div class="row">
675
+ {% for item in items %}
676
+ <div class="col-md-4 mb-4">
677
+ <div class="card menu-card position-relative">
678
+ <img src="{{ item.Image1__c }}" class="card-img-top menu-image" alt="{{ item.Name }}"
679
+ onerror="this.src='/static/placeholder.jpg';" loading="lazy">
680
+
681
+ <!-- Customize Button on Image -->
682
+ <button class="btn customize-btn position-absolute"
683
+ data-bs-toggle="modal" data-bs-target="#itemModal"
684
+ onclick="showItemDetails('{{ item.Name }}', '{{ item.Price__c }}', '{{ item.Image2__c }}', '{{ item.Description__c }}', '{{ item.Section__c }}','{{ selected_category }}')">
685
+ Customize <i class="bi bi-caret-right-fill"></i>
686
+ </button>
687
+
688
+ <div class="card-body">
689
+ <div class="d-flex justify-content-between align-items-center">
690
+ <h5 class="card-title">{{ item.Name }}</h5>
691
+ <p class="card-text">${{ item.Price__c }}</p>
692
+ </div>
693
+
694
+ <div class="d-flex justify-content-between">
695
+ <!-- Add Button -->
696
+ <button class="btn btn-danger">
697
+ Add
698
+ </button>
699
+ </div>
700
  </div>
701
+ </div>
702
+ </div>
703
+ {% endfor %}
704
+ </div>
705
+
706
  {% endfor %}
707
  </div>
708
  {% endif %}