PageSourceSearch

https://gettopdiscounts.com/_next/static/chunks/7724.d582d840c542708f.js

js gettopdiscounts.com collected 2026-10-05 06:50:54 UTC 3,532 bytes, 2 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7724],{67724:(e,t,a)=>{a.r(t),a.d(t,{default:()=>d});var r=a(61975),s=a(22043),o=a(71450),n=a(95155),l=a(22437),c=a(76296),i=a(12115),u=a(12008);let d=e=>{var t=e.offer_id,a=e.company_id,d=(0,s._)((0,i.useState)(0),2),f=d[0],m=d[1],h=(0,s._)((0,i.useState)(""),2),g=h[0],x=h[1],p=(0,s._)((0,i.useState)(!1),2),b=p[0],y=p[1],v=(0,s._)((0,i.useState)(!1),2),w=v[0],k=v[1];return(0,i.useEffect)(()=>{var e=localStorage.getItem(`hasRated_${t}`);e&&new Date().getTime()-parseInt(e)<864e5&&k(!0)},[t]),(0,n.jsxs)("div",{className:"p-6 bg-white rounded-3xl border border-gray-100 shadow-sm",children:[(0,n.jsx)(u.ToastContainer,{}),(0,n.jsx)("h4",{className:"text-lg font-black text-gray-900 mb-4 uppercase tracking-wider",children:"Rate This Offer"}),(0,n.jsxs)("form",{onSubmit:e=>(0,r._)(function(){return(0,o.YH)(this,function(s){let n;return(e.preventDefault(),w)?u.toast.error("You have already rated, please try again later!",{autoClose:2e3}):((0,r._)(function(){var e;return(0,o.YH)(this,function(r){switch(r.label){case 0:if(!f&&!g.trim())return u.toast.error("Please select a rating or add a comment.",{autoClose:2e3}),[2];y(!0),r.label=1;case 1:return r.trys.push([1,3,4,5]),[4,(0,l.rA)(t,a,g,f.toString())];case 2:return"success"===(e=r.sent()).status||200===e.status?(u.toast.success("Thank you for your feedback!",{autoClose:2e3}),m(0),x("")):u.toast.error("An error occurred. Please try again later!",{autoClose:2e3}),[3,5];case 3:return r.sent(),u.toast.error("An error occurred while submitting feedback.",{autoClose:2e3}),[3,5];case 4:return y(!1),[7];case 5:return[2]}})})(),localStorage.setItem(`hasRated_${t}`,new Date().getTime().toString()),k(!0)),[2]})})(),autoComplete:"off",className:"space-y-6",children:[(0,n.jsxs)("div",{className:"space-y-2",children:[(0,n.jsx)("div",{className:"flex items-center gap-2",children:[void 0,void 0,void 0,void 0,void 0].map((e,t)=>(0,n.jsx)("button",{type:"button",onClick:()=>{m(t+1)},className:"focus:outline-none transform transition-transform active:scale-90",children:(0,n.jsx)(c.gc,{icon:t<f?c.xq:c.C1,className:`w-6 h-6 ${t<f?"text-yellow-400":"text-gray-200"} transition-colors duration-200`})},t))}),(0,n.jsx)("p",{className:"text-xs font-bold text-gray-400 uppercase tracking-widest",children:f?`${f} Star${f>1?"s":""}`:"Select Rating"})]}),(0,n.jsxs)("div",{className:"space-y-2",children:[(0,n.jsx)("label",{htmlFor:"comment",className:"text-xs font-black text-gray-900 uppercase tracking-widest block",children:"Add a Comment"}),(0,n.jsx)("textarea",{id:"comment",placeholder:"Share your experience...",className:"w-full px-4 py-3 rounded-2xl bg-gray-50 border border-transparent focus:bg-white focus:border-[#f23017] focus:ring-4 focus:ring-[#f2301710] transition-all duration-300 resize-none h-24 text-sm text-gray-700 outline-none",value:g,onChange:e=>x(e.target.value)})]}),(0,n.jsx)("button",{type:"submit",disabled:b||w&&0===f&&""===g,className:"w-full py-4 rounded-2xl bg-[#f23017] text-white text-xs font-black uppercase tracking-[0.2em] hover:bg-[#ff912f] transition-all duration-500 shadow-lg shadow-[#f2301720] hover:shadow-[#ff912f40] disabled:opacity-50 disabled:cursor-not-allowed group",children:b?"Submitting...":(0,n.jsxs)("span",{className:"flex items-center justify-center gap-2",children:["Submit Feedback",(0,n.jsx)("span",{className:"transform group-hover:translate-x-1 transition-transform duration-300"})]})})]})]})}}}]);
2//# sourceMappingURL=7724.d582d840c542708f.js.map

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.