1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8425],{78425:function(n,e,t){t.r(e);var s=t(47568),i=t(7297),a=t(97582),r=t(85893),l=t(26601),o=t(27484),d=t.n(o),c=t(67294),p=t(8151);function f(){var n=(0,i.Z)(["\n padding: 0 10px;\n\n .widget-oil-stat-box {\n display: flex;\n flex-wrap: wrap;\n flex-direction: row;\n\n .widget-oil-stat-list {\n width: 18%;\n\n &.--head {\n width: 10%;\n text-transform: uppercase;\n p {\n text-align: left;\n font-weight: bolder;\n font-size: 18px;\n\n &:nth-child(1) {\n padding: 5px 0;\n background-color: #fff;\n }\n }\n\n @media (max-width: 540px) {\n font-size: 14px;\n }\n @media (max-width: 380px) {\n p {\n font-size: 14px;\n }\n }\n }\n\n @media (max-width: 899px) {\n width: 100%;\n display: flex;\n justify-content: space-between;\n align-items: center;\n\n &.--head {\n width: 100%;\n }\n\n .type-1,\n .type-2,\n .type-3,\n .type-4,\n .type-5 {\n padding: 5px 15px !important;\n }\n }\n\n .type-1 {\n background-color: #6c0793;\n color: #fff;\n text-transform: uppercase;\n font-weight: bolder;\n padding: 5px 0;\n }\n .type-2 {\n background-color: #2552cc;\n color: #fff;\n text-transform: uppercase;\n font-weight: bolder;\n padding: 5px 0;\n }\n .type-3 {\n background-color: #63962c;\n color: #fff;\n text-transform: uppercase;\n font-weight: bolder;\n padding: 5px 0;\n }\n .type-4 {\n background-color: #ff9900;\n color: #fff;\n text-transform: uppercase;\n font-weight: bolder;\n padding: 5px 0;\n }\n .type-5 {\n background-color: #9ae54d;\n color: #fff;\n text-transform: uppercase;\n font-weight: bolder;\n padding: 5px 0;\n }\n\n p {\n text-align: center;\n margin-bottom: 15px;\n font-weight: bold; //before ligther\n font-size: 18px;\n @media (max-width: 992px) {\n font-weight: bold;\n font-size: 16px;\n }\n @media (max-width: 475px) {\n font-weight: bold;\n font-size: 15px;\n }\n }\n }\n }\n"]);return f=function(){return n},n}e.default=function(){var n=(0,c.useState)(null),e=n[0],t=n[1];(0,c.useEffect)((function(){(0,s.Z)((function(){var n,e;return(0,a.__generator)(this,(function(s){switch(s.label){case 0:return s.trys.push([0,3,,4]),[4,fetch("".concat(p.Tr,"/oil"))];case 1:return[4,s.sent().json()];case 2:if(!(n=s.sent()))throw new TypeError;return t(n),[3,4];case 3:return e=s.sent(),console.error("==========> WIDGET_OIL ERROR :",e),[3,4];case 4:return[2]}}
1))}))()}),[]);var i=d()(null===e||void 0===e?void 0:e.datetime).locale("en").format("DD MMM YYYY");return(0,r.jsx)(x,{children:null!==e&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)("div",{className:"widget-oil-stat-box",children:[(0,r.jsxs)("div",{className:"widget-oil-stat-list --head",children:[(0,r.jsx)("p",{children:"Types"}),(0,r.jsx)("p",{children:"Baht/Litre"})]}),(0,r.jsxs)("div",{className:"widget-oil-stat-list",children:[(0,r.jsx)("p",{className:"type-1",children:"Diesel"}),(0,r.jsx)("p",{children:e.Diesel})]}),(0,r.jsxs)("div",{className:"widget-oil-stat-list",children:[(0,r.jsx)("p",{className:"type-2",children:"Diesel B10"}),(0,r.jsx)("p",{children:e.DieselB10})]}),(0,r.jsxs)("div",{className:"widget-oil-stat-list",children:[(0,r.jsx)("p",{className:"type-3",children:"Gasohol 91"}),(0,r.jsx)("p",{children:e.Gasohol91})]}),(0,r.jsxs)("div",{className:"widget-oil-stat-list",children:[(0,r.jsx)("p",{className:"type-4",children:"Gasohol 95"}),(0,r.jsx)("p",{children:e.Gasohol95})]}),(0,r.jsxs)("div",{className:"widget-oil-stat-list",children:[(0,r.jsx)("p",{className:"type-5",children:"Gasohol E20"}),(0,r.jsx)("p",{children:e.GasoholE20})]})]}),(0,r.jsxs)("p",{className:"date-update",children:[" SOURCE: PTT (",i,") "]})]})})};var x=l.default.div(f())}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.