60e2149072
Tasks 16-20: Online Board Tests (Search/Filter, Tabs, Flight List, Details Modal, Time/Date) - Task 16: Search & Filter tests (37 tests) - departure/arrival cities, passenger count, cabin class - Task 17: Arrival/Departure Tabs tests (45 tests) - tab switching, flight display, sorting - Task 18: Flight List View tests (50 tests) - display, sorting, filtering, pagination, loading states - Task 19: Flight Details Modal tests (40 tests) - opening/closing, content display, actions - Task 20: Time & Date Filter tests (43 tests) - date selection, time ranges, calendar navigation Tasks 21-25: Flight Details Tests (Flight Info, Passengers, Seats, Services, Fares) - Task 21: Flight Info Display tests (40 tests) - basic info, airports, route visualization, timeline - Task 22: Passenger Info tests (50 tests) - passenger list, details, services, special requirements - Task 23: Seat Selection tests (50 tests) - seat map, selection, categories, recommendations - Task 24: Service Selection tests (25 tests) - baggage, meals, seats, summary - Task 25: Fare Display tests (55 tests) - fare breakdown, comparisons, discounts, refunds All tests follow AAA pattern and use data-testid selectors matching Angular version. Total: 245 tests across 10 feature suites.
2 lines
2.5 KiB
JavaScript
2 lines
2.5 KiB
JavaScript
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("primereact/api"),r=require("primereact/componentbase"),n=require("primereact/hooks"),u=require("primereact/utils");function a(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(r){if("default"!==r){var n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:function(){return e[r]}})}})),t.default=e,Object.freeze(t)}var i=a(e),s=r.ComponentBase.extend({defaultProps:{__TYPE:"Chart",id:null,type:null,data:null,options:null,plugins:null,width:null,height:null,style:null,className:null,children:void 0},css:{classes:{root:"p-chart"},inlineStyles:{root:function(e){var t=e.props;return Object.assign({width:t.width,height:t.height},t.style)}},styles:"\n @layer primereact {\n .p-chart {\n position: relative\n }\n }\n "}}),o=function(){try{return Chart}catch(e){return null}}(),c=i.memo(i.forwardRef((function(e,c){var l=n.useMergeProps(),p=i.useContext(t.PrimeReactContext),f=s.getProps(e,p),d=s.setMetaData({props:f}),h=d.ptm,g=d.cx,m=d.sx;r.useHandleStyle(s.css.styles,d.isUnstyled,{name:"chart"});var y=i.useRef(null),v=i.useRef(null),b=i.useRef(null),w=function(){P();var e={type:f.type,data:f.data,options:f.options,plugins:f.plugins};o?v.current=new o(b.current,e):Promise.resolve().then((function(){return a(require("chart.js/auto"))})).then((function(t){P(),b.current&&t&&(v.current=t.default?new t.default(b.current,e):new t(b.current,e))}))},P=function(){v.current&&(v.current.destroy(),v.current=null)};i.useImperativeHandle(c,(function(){return{props:f,getCanvas:function(){return b.current},getChart:function(){return v.current},getBase64Image:function(){return v.current.toBase64Image()},getElement:function(){return y.current},generateLegend:function(){return v.current&&v.current.generateLegend()},refresh:function(){return v.current&&v.current.update()}}})),i.useEffect((function(){w()})),n.useUnmountEffect((function(){P()}));var C=f.ariaLabel||f.options&&f.options.plugins&&f.options.plugins.title&&f.options.plugins.title.text,O=l({id:f.id,ref:y,style:m("root"),className:u.classNames(f.className,g("root"))},s.getOtherProps(f),h("root")),j=l({ref:b,width:f.width,height:f.height,role:"img","aria-label":C},h("canvas"));return i.createElement("div",O,i.createElement("canvas",j))})),(function(e,t){return e.data===t.data&&e.options===t.options&&e.type===t.type}));c.displayName="Chart",exports.Chart=c;
|