PageSourceSearch

https://fossilsketch.org/_next/static/chunks/pages/instructor/new_fossil-d108028c811089b9.js

js fossilsketch.org collected 2026-10-09 00:41:42 UTC 45,467 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6710],{3451:function(e,a,l){(window.__NEXT_P=window.__NEXT_P||[]).push(["/instructor/new_fossil",function(){return l(5187)}])},5187:function(e,a,l){"use strict";l.r(a),l.d(a,{default:function(){return Be}});var t=l(8788),n=l(7842),r=l(2838),o=l(865),s=l(6670),i=l(930),c=l(2970),u=l(2322),d=l(2784),p=l(1783),h=l(6759),m=l(8327),f=l.n(m),v=l(1141),g=l(7841),b=l(5117),x=l(2623),y=l(9236),j=l(8090),_=l(5851),C=l(6817),w=(0,C.k)((e=>({placeholder:{color:"dark"===e.colorScheme?e.colors.dark[3]:e.colors.gray[5]},input:{cursor:"pointer"}}))),S=l(6261),k=l(971),T=l(6720),O=l(4761),A=l(3979),N=l(665),F=Object.defineProperty,z=Object.getOwnPropertySymbols,P=Object.prototype.hasOwnProperty,E=Object.prototype.propertyIsEnumerable,Y=(e,a,l)=>a in e?F(e,a,{enumerable:!0,configurable:!0,writable:!0,value:l}):e[a]=l;const R={multiple:!1},W=(0,d.forwardRef)(((e,a)=>{const l=(0,O.N4)("FileButton",R,e),{onChange:t,children:n,multiple:r,accept:o,name:s,form:i,resetRef:c}=l,u=((e,a)=>{var l={};for(var t in e)P.call(e,t)&&a.indexOf(t)<0&&(l[t]=e[t]);if(null!=e&&z)for(var t of z(e))a.indexOf(t)<0&&E.call(e,t)&&(l[t]=e[t]);return l})(l,["onChange","children","multiple","accept","name","form","resetRef"]),p=(0,d.useRef)();return(0,A.k)(c,(()=>{p.current.value=""})),d.createElement(d.Fragment,null,n(((e,a)=>{for(var l in a||(a={}))P.call(a,l)&&Y(e,l,a[l]);if(z)for(var l of z(a))E.call(a,l)&&Y(e,l,a[l]);return e})({onClick:()=>{p.current.click()}},u)),d.createElement("input",{style:{display:"none"},type:"file",accept:o,multiple:r,onChange:e=>{t(r?Array.from(e.currentTarget.files):e.currentTarget.files[0]||null)},ref:(0,N.Y)(a,p),name:s,form:i}))}));W.displayName="@mantine/core/FileButton";var I=Object.defineProperty,M=Object.defineProperties,X=Object.getOwnPropertyDescriptors,D=Object.getOwnPropertySymbols,L=Object.prototype.hasOwnProperty,B=Object.prototype.propertyIsEnumerable,U=(e,a,l)=>a in e?I(e,a,{enumerable:!0,configurable:!0,writable:!0,value:l}):e[a]=l,Z=(e,a)=>{for(var l in a||(a={}))L.call(a,l)&&U(e,l,a[l]);if(D)for(var l of D(a))B.call(a,l)&&U(e,l,a[l]);return e},H=(e,a)=>M(e,X(a));const G={size:"sm",valueComponent:({value:e})=>d.createElement("span",null,Array.isArray(e)?e.map((e=>e.name)).join(", "):null==e?void 0:e.name),clearButtonTabIndex:0},$={xs:24,sm:30,md:34,lg:40,xl:44},V=(0,d.forwardRef)(((e,a)=>{const l=(0,S.k)("FileInput",G,e),{inputProps:t,wrapperProps:n,placeholder:r,value:o,defaultValue:s,onChange:i,multiple:c,accept:u,name:p,form:h,classNames:m,styles:f,unstyled:v,valueComponent:g,rightSection:b,rightSectionWidth:x,clearable:y,clearButtonLabel:j,clearButtonTabIndex:C}=l,O=((e,a)=>{var l={};for(var t in e)L.call(e,t)&&a.indexOf(t)<0&&(l[t]=e[t]);if(null!=e&&D)for(var t of D(e))a.indexOf(t)<0&&B.call(e,t)&&(l[t]=e[t]);return l})(l,["inputProps","wrapperProps","placeholder","value","defaultValue","onChange","multiple","accept","name","form","classNames","styles","unstyled","valueComponent","rightSection","rightSectionWidth","clearable","clearButtonLabel","clearButtonTabIndex"]),A=(0,d.useRef)(),{classes:N,theme:F,cx:z}=w(null,{name:"FileInput",classNames:m,styles:f,unstyled:v}),[P,E]=(0,_.C)({value:o,defaultValue:s,onChange:i,finalValue:c?[]:null}),Y=Array.isArray(P)?0!==P.length:null!==P,R=b||(y&&Y?d.createElement(k.P,{variant:"transparent","aria-label":j,onClick:()=>E(c?[]:null),size:t.size,tabIndex:C,unstyled:v}):null);return(0,d.useEffect)((()=>{(Array.isArray(P)&&0===P.length||null===P)&&A.current()}),[P]),d.createElement(T.I.Wrapper,H(Z({},n),{__staticSelector:"FileInput"}),d.createElement(W,{onChange:E,multiple:c,accept:u,name:p,form:h,resetRef:A},(e=>d.createElement(T.I,H(Z(Z(Z({multiline:!0},e),t),O),{component:"button",type:"button",ref:a,__staticSelector:"FileInput",rightSection:R,rightSectionWidth:x||F.fn.size({size:t.size,sizes:$}),classNames:H(Z({},m),{input:z(N.input,null==m?void 0:m.input)})}),Y?d.createElement(g,{value:P}):d.createElement("span",{className:N.placeholder},r)))))}));V.displayName="@mantine/core/FileInput";const K=V;var Q=l(61),J=l(8393),q=l(50),ee=l(3524),ae=l(6289);const le={x:0,y:0,width:0,height:0,top:0,left:0,bottom:0,right:0};function te(){const e=(0,d.useRef)(0),a=(0,d.useRef)(null),[l,t]=(0,d.useState)(le),n=(0,d.useMemo)((()=>"undefined"!==typeof window?new ResizeObserver((l=>{const n=l[0];n&&(cancelAnimationFrame(e.current),e.current=requestAnimationFrame((()=>{a.current&&t(n.contentRect)})))})):null),[]);return(0,d.useEffect)((()=>(a.current&&n.observe(a.current),()=>{n.disconnect(),e.current&&cancelAnimationFrame(e.current)})),[a.current]),[a,l]}var ne=l(129),re=Object.defineProperty,oe=Object.defineProperties,se=Object.getOwnPropertyDescriptors,ie=Object.getOwnPropertySymbols,ce=Object.prototype.hasOwnProperty,ue=Object.prototype.propertyIsEnumerable,de=(e,a,l)=>a in e?re(e,a,{enumerable:!0,configurable:!0,writable:!0,value:l}):e[a]=l,pe=(e,a)=>{for(var l in a||(a={}))ce.call(a,l)&&de(e,l,a[l]);if(ie)for(var l of ie(a))ue.call(a,l)&&de(e,l,a[l]);return e};const he={xs:"3px 6px",sm:"5px 10px",md:"7px 14px",lg:"9px 16px",xl:"12px 20px"};var me=(0,C.k)(((e,{fullWidth:a,color:l,radius:t,shouldAnimate:n,transitionDuration:r,transitionTimingFunction:o,size:s,orientation:i},c)=>{const u="vertical"===i,d=e.fn.variant({variant:"filled",color:l});return{label:(p=pe(pe({ref:c("label")},e.fn.focusStyles()),e.fn.fontStyles()),h={WebkitTapHighlightColor:"transparent",borderRadius:e.fn.radius(t),fontWeight:500,fontSize:s in e.fontSizes?e.fontSizes[s]:e.fontSizes.sm,curs
1or:"pointer",display:"block",textAlign:"center",padding:he[s in he?s:"sm"],whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",userSelect:"none",color:"dark"===e.colorScheme?e.colors.dark[1]:e.colors.gray[7],transition:`color ${n?0:r}ms ${o||e.transitionTimingFunction}`,"&:hover":{color:"dark"===e.colorScheme?e.colors.dark[0]:e.black}},oe(p,se(h))),control:{ref:c("control"),position:"relative",boxSizing:"border-box",flex:1,zIndex:2,transition:`border-left-color ${n?0:r}ms ${o||e.transitionTimingFunction}`,"&:not(:first-of-type)":{borderStyle:"solid",borderWidth:u?"1px 0 0 0":"0 0 0 1px",borderColor:"dark"===e.colorScheme?e.colors.dark[4]:e.colors.gray[3]}},input:{height:0,width:0,position:"absolute",overflow:"hidden",whiteSpace:"nowrap",opacity:0,"&:focus":{outline:"none",[`& + .${c("label")}`]:{outline:"none",boxShadow:"always"===e.focusRing||"auto"===e.focusRing?`0 0 0 2px ${"dark"===e.colorScheme?e.colors.dark[9]:e.white}, 0 0 0 4px ${e.colors[e.primaryColor]["dark"===e.colorScheme?7:5]}`:void 0},"&:focus:not(:focus-visible)":{[`& + .${c("label")}`]:{boxShadow:"auto"===e.focusRing||"never"===e.focusRing?"none":void 0}}}},root:{position:"relative",display:a||u?"flex":"inline-flex",width:u&&!a?"max-content":"auto",flexDirection:u?"column":"row",backgroundColor:"dark"===e.colorScheme?e.colors.dark[8]:e.colors.gray[1],borderRadius:e.fn.radius(t),overflow:"hidden",padding:4},controlActive:{borderLeftColor:"transparent !important",borderTopColor:"transparent !important",[`& + .${c("control")}`]:{borderLeftColor:"transparent !important",borderTopColor:"transparent !important"},borderRadius:e.fn.radius(t),boxShadow:n?l||"dark"===e.colorScheme?"none":e.shadows.xs:void 0,backgroundColor:n?l in e.colors?d.background:"dark"===e.colorScheme?e.colors.dark[5]:e.white:void 0},labelActive:{"&, &:hover":{color:l in e.colors||"dark"===e.colorScheme?e.white:e.black}},disabled:{"&, &:hover":{color:"dark"===e.colorScheme?e.colors.dark[3]:e.colors.gray[5],cursor:"not-allowed"}},active:{boxSizing:"border-box",borderRadius:e.fn.radius(t),position:"absolute",zIndex:1,boxShadow:l||"dark"===e.colorScheme?"none":e.shadows.xs,transition:`transform ${n?0:r}ms ${e.transitionTimingFunction}, width ${n?0:r/2}ms ${o||e.transitionTimingFunction}`,backgroundColor:l in e.colors?d.background:"dark"===e.colorScheme?e.colors.dark[5]:e.white}};var p,h})),fe=l(4459),ve=Object.defineProperty,ge=Object.getOwnPropertySymbols,be=Object.prototype.hasOwnProperty,xe=Object.prototype.propertyIsEnumerable,ye=(e,a,l)=>a in e?ve(e,a,{enumerable:!0,configurable:!0,writable:!0,value:l}):e[a]=l;const je={disabled:!1,size:"sm",transitionDuration:200},_e=(0,d.forwardRef)(((e,a)=>{var l,t,n,r;const o=(0,O.N4)("SegmentedControl",je,e),{className:s,disabled:i,data:c,name:u,value:p,onChange:h,color:m,fullWidth:f,radius:v,size:g,transitionDuration:b,transitionTimingFunction:x,classNames:y,styles:j,defaultValue:C,orientation:w,unstyled:S}=o,k=((e,a)=>{var l={};for(var t in e)be.call(e,t)&&a.indexOf(t)<0&&(l[t]=e[t]);if(null!=e&&ge)for(var t of ge(e))a.indexOf(t)<0&&xe.call(e,t)&&(l[t]=e[t]);return l})(o,["className","disabled","data","name","value","onChange","color","fullWidth","radius","size","transitionDuration","transitionTimingFunction","classNames","styles","defaultValue","orientation","unstyled"]),T=(0,O.rZ)(),A=(0,ee.J)(),F=!!T.respectReducedMotion&&A,z=c.map((e=>"string"===typeof e?{label:e,value:e}:e)),P=(0,d.useRef)(),[E,Y]=(0,d.useState)(!1),[R,W]=(0,_.C)({value:p,defaultValue:C,finalValue:Array.isArray(z)&&null!=(r=null!=(n=null==(l=z.find((e=>!e.disabled)))?void 0:l.value)?n:null==(t=z[0])?void 0:t.value)?r:null,onChange:h}),{classes:I,cx:M}=me({size:g,fullWidth:f,color:m,radius:v,shouldAnimate:F||!E,transitionDuration:b,transitionTimingFunction:x,orientation:w},{classNames:y,styles:j,unstyled:S,name:"SegmentedControl"}),[X,D]=(0,d.useState)({width:0,height:0,translate:[0,0]}),L=(0,ae.M)(u),B=(0,d.useRef)({}),[U,Z]=te();(0,ne.Y)((()=>{P.current?Y(!0):(P.current=!0,Y(!1))})),(0,d.useEffect)((()=>{if(R in B.current&&U.current){const e=B.current[R],a=e.getBoundingClientRect(),l=e.offsetWidth/a.width,t=a.width*l||0,n=a.height*l||0,r=Z.width-e.parentElement.offsetLeft+4-t,o=e.parentElement.offsetLeft-4;D({width:t,height:n,translate:["rtl"===T.dir?r:o,e.parentElement.offsetTop-4]}
1)}}),[R,Z]);const H=z.map((e=>d.createElement("div",{className:M(I.control,{[I.controlActive]:R===e.value}),key:e.value},d.createElement("input",{className:I.input,disabled:i||e.disabled,type:"radio",name:L,value:e.value,id:`${L}-${e.value}`,checked:R===e.value,onChange:()=>W(e.value)}),d.createElement("label",{className:M(I.label,{[I.labelActive]:R===e.value,[I.disabled]:i||e.disabled}),htmlFor:`${L}-${e.value}`,ref:a=>{B.current[e.value]=a}},e.label))));return 0===z.length?null:d.createElement(fe.x,((e,a)=>{for(var l in a||(a={}))be.call(a,l)&&ye(e,l,a[l]);if(ge)for(var l of ge(a))xe.call(a,l)&&ye(e,l,a[l]);return e})({className:M(I.root,s),ref:(0,N.Y)(U,a)},k),"string"===typeof R&&E&&d.createElement(fe.x,{component:"span",className:I.active,sx:{width:X.width,height:X.height,transform:`translate(${X.translate[0]}px, ${X.translate[1]}px )`}}),H)}));_e.displayName="@mantine/core/SegmentedControl";var Ce=l(8855),we=l(9834),Se=l(3575),ke=l(7973),Te=l(8181),Oe=l(8409),Ae=["size","color"];function Ne(e){var a=e.size,l=void 0===a?24:a,t=e.color,n=void 0===t?"currentColor":t,r=(0,Oe.Kd)(e,Ae);return d.createElement("svg",(0,Oe.gY)({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-minus",width:l,height:l,viewBox:"0 0 24 24",stroke:n,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},r),d.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),d.createElement("line",{x1:"5",y1:"12",x2:"19",y2:"12"}))}var Fe=l(7082),ze=l(2589),Pe=l(9454),Ee=l(5632),Ye=l(5056),Re=l(8654),We=l(8078),Ie=function(e){var a,l=e.fossilState,t=e.radioControl,n=e.checkboxControl,r=e.inputControl,o=t.setVariation,s=t.setShape,i=t.setSmoothOrnamented,c=n.setSize,d=n.setOrnamentation,p=n.setOtherFeatures,h=r.setWidthInMm;return(0,u.jsxs)("div",{children:[(0,u.jsxs)(Re.Y.Group,{style:{marginTop:"5%"},label:"Is this a left valve or right valve?",onChange:o,value:l.variation,withAsterisk:!0,children:[(0,u.jsx)(Re.Y,{value:"left",label:"Left"}),(0,u.jsx)(Re.Y,{value:"right",label:"Right"})]}),(0,u.jsxs)(Re.Y.Group,{style:{marginTop:"5%"},label:"What shape is this valve?",onChange:s,value:l.shape,withAsterisk:!0,children:[(0,u.jsx)(Re.Y,{value:"Bean",label:"Bean"}),(0,u.jsx)(Re.Y,{value:"Oval",label:"Oval"}),(0,u.jsx)(Re.Y,{value:"Triangular",label:"Triangular"}),(0,u.jsx)(Re.Y,{value:"Rectangular",label:"Rectangular"}),(0,u.jsx)(Re.Y,{value:"Circular",label:"Circular"})]}),(0,u.jsxs)(We.X.Group,{style:{marginTop:"5%"},label:"What is the approximate size of the valve?",onChange:c,defaultValue:l.size,withAsterisk:!0,children:[(0,u.jsx)(We.X,{value:"Small",label:"Small"}),(0,u.jsx)(We.X,{value:"Medium",label:"Medium"}),(0,u.jsx)(We.X,{value:"Large",label:"Large"})]}),(0,u.jsx)(Q.o,{style:{marginTop:"5%"},defaultValue:null===(a=l.widthInMm)||void 0===a?void 0:a.toString(),label:"What is the maximum length of the valve in millimetres?",onChange:function(e){h(parseFloat(e.currentTarget.value))},withAsterisk:!0}),(0,u.jsxs)(Re.Y.Group,{style:{marginTop:"5%"},label:"Is it smooth or ornamented",onChange:i,value:l.smoothOrnamented,withAsterisk:!0,children:[(0,u.jsx)(Re.Y,{value:"Smooth",label:"Smooth"}),(0,u.jsx)(Re.Y,{value:"Ornamented",label:"Ornamented"})]}),(0,u.jsxs)(We.X.Group,{style:{marginTop:"5%"},label:"What are the ornamentation features?",onChange:d,defaultValue:l.ornamentation,children:[(0,u.jsx)(We.X,{value:"Punctate",label:"Punctate"}),(0,u.jsx)(We.X,{value:"Spinose",label:"Spinose"}),(0,u.jsx)(We.X,{value:"Reticulated",label:"Reticulated"}),(0,u.jsx)(We.X,{value:"Tubercules",label:"Tubercules"}),(0,u.jsx)(We.X,{value:"Ribs",label:"Ribs"}),(0,u.jsx)(We.X,{value:"Ridges",label:"Ridges"})]}),(0,u.jsxs)(We.X.Group,{style:{marginTop:"5%"},label:"Other characteristic carapace features?",onChange:p,value:l.otherFeatures,children:[(0,u.jsx)(We.X,{value:"Caudal Process",label:"Caudal Process"}),(0,u.jsx)(We.X,{value:"Alae",label:"Alae"})]})]})},Me=function(e){var a=e.fossilState,l=e.radioControl,t=e.checkboxControl,n=l.setShellType,r=l.setNumberChambers,o=l.setApertureLocation,s=l.setApertureShape,i=l.setMorphotype,c=l.setImageType,d=t.setOverallShape,p=t.setChamberShape,h=t.setChamberArrangement;return(0,u.jsxs)("div",{children:[(0,u.jsxs)(Re.Y.Group,{style:{marginTop:"5%"}
1,label:"What type of shell does the foraminifer have?",onChange:n,value:a.shellType,withAsterisk:!0,children:[(0,u.jsx)(Re.Y,{value:"Agglutinated",label:"Agglutinated"}),(0,u.jsx)(Re.Y,{value:"Hyaline",label:"Hyaline"}),(0,u.jsx)(Re.Y,{value:"Porcellaneous ",label:"Porcellaneous "})]}),(0,u.jsxs)(We.X.Group,{style:{marginTop:"5%"},label:"What is the overall shape of the organism?",onChange:d,defaultValue:a.overallShape,withAsterisk:!0,children:[(0,u.jsx)(We.X,{value:"Lenticular",label:"Lenticular"}),(0,u.jsx)(We.X,{value:"Planoconvex",label:"Planoconvex"}),(0,u.jsx)(We.X,{value:"Discoidal",label:"Discoidal"}),(0,u.jsx)(We.X,{value:"Spherical to Ovate",label:"Spherical to Ovate"}),(0,u.jsx)(We.X,{value:"Elongate Cylindrical",label:"Elongate Cylindrical"}),(0,u.jsx)(We.X,{value:"Elongate Flattened",label:"Elongate Flattened"}),(0,u.jsx)(We.X,{value:"Tubular or Branching",label:"Tubular or Branching"}),(0,u.jsx)(We.X,{value:"Pyramidal",label:"Pyramidal"})]}),(0,u.jsxs)(We.X.Group,{style:{marginTop:"5%"},label:"What is the chamber shape?",onChange:p,defaultValue:a.chamberShape,withAsterisk:!0,children:[(0,u.jsx)(We.X,{value:"Angular",label:"Angular"}),(0,u.jsx)(We.X,{value:"Tubular",label:"Tubular"}),(0,u.jsx)(We.X,{value:"Broad and Low",label:"Broad and Low"}),(0,u.jsx)(We.X,{value:"Inflated to Globose",label:"Inflated to Globose"}),(0,u.jsx)(We.X,{value:"Arched",label:"Arched"}),(0,u.jsx)(We.X,{value:"Narrow and High",label:"Narrow and High"})]}),(0,u.jsxs)(Re.Y.Group,{style:{marginTop:"5%"},label:"How many chambers are visible?",onChange:r,value:a.numberChambers,withAsterisk:!0,children:[(0,u.jsx)(Re.Y,{value:"1",label:"1"}),(0,u.jsx)(Re.Y,{value:"2-5",label:"2-5"}),(0,u.jsx)(Re.Y,{value:"Many",label:"Many"})]}),(0,u.jsxs)(We.X.Group,{style:{marginTop:"5%"},label:"What is the chamber arrangement?",onChange:h,defaultValue:a.chamberArrangement,withAsterisk:!0,children:[(0,u.jsx)(We.X,{value:"Planispiral",label:"Planispiral"}),(0,u.jsx)(We.X,{value:"High Trochospiral",label:"High Trochospiral"}),(0,u.jsx)(We.X,{value:"Low Trochospiral",label:"Low Trochospiral"}),(0,u.jsx)(We.X,{value:"Uniserial",label:"Uniserial"}),(0,u.jsx)(We.X,{value:"Biserial",label:"Biserial"}),(0,u.jsx)(We.X,{value:"Triserial",label:"Triserial"}),(0,u.jsx)(We.X,{value:"Unilocular",label:"Unilocular"}),(0,u.jsx)(We.X,{value:"Millioline",label:"Millioline "}),(0,u.jsx)(We.X,{value:"Enrolled Biserial",label:"Enrolled Biserial"}),(0,u.jsx)(We.X,{value:"Mixed",label:"Mixed"})]}),(0,u.jsxs)(Re.Y.Group,{style:{marginTop:"5%"},label:"Where is the aperture located?",onChange:o,value:a.apertureLocation,withAsterisk:!0,children:[(0,u.jsx)(Re.Y,{value:"Terminal",label:"Terminal"}),(0,u.jsx)(Re.Y,{value:"Areal",label:"Areal"}),(0,u.jsx)(Re.Y,{value:"Basal/Interiomarginal",label:"BasalInteriomarginal"}),(0,u.jsx)(Re.Y,{value:"Umbilical",label:"Umbilical"})]}),(0,u.jsxs)(Re.Y.Group,{style:{marginTop:"5%"},label:"What is the aperture's shape?",onChange:s,value:a.apertureShape,withAsterisk:!0,children:[(0,u.jsx)(Re.Y,{value:"Radiate",label:"Radiate"}),(0,u.jsx)(Re.Y,{value:"Arch/Slit",label:"Arch/Slit"}),(0,u.jsx)(Re.Y,{value:"Loop-shaped",label:"Loop"}),(0,u.jsx)(Re.Y,{value:"Circular/Ovate",label:"Circular/Ovate"}),(0,u.jsx)(Re.Y,{value:"Many Pores",label:"Many Pores"})]}),(0,u.jsxs)(Re.Y.Group,{style:{marginTop:"5%"},label:"What morphotype is the foraminifer?",onChange:i,value:a.morphotype,withAsterisk:!0,children:[(0,u.jsx)(Re.Y,{value:"Biconvex Rounded",label:"Biconvex Rounded"}),(0,u.jsx)(Re.Y,{value:"Flat Discoidal",label:"Flat Discoidal"}),(0,u.jsx)(Re.Y,{value:"Biconvex Keeled",label:"Biconvex Keeled"}),(0,u.jsx)(Re.Y,{value:"Cylindrical Tapered",label:"Cylindrical Tapered"}),(0,u.jsx)(Re.Y,{value:"Flat Tapered",label:"Flat Tapered"}),(0,u.jsx)(Re.Y,{value:"Spherical to Ovate",label:"Spherical to Ovate"}),(0,u.jsx)(Re.Y,{value:"Rounded Discoidal",label:"Rounded Discoidal"}),(0,u.jsx)(Re.Y,{value:"Planoconvex",label:"Planoconvex"}),(0,u.jsx)(Re.Y,{value:"Convex-concave",label:"Convex-concave"}),(0,u.jsx)(Re.Y,{value:"Cylindrical tubular",label:"Cylindrical tubular"}),(0,u.jsx)(Re.Y,{value:"Branching",label:"Branching"}),(0,u.jsx)(Re.Y,{value:"Pyramidal",label:"Pyramidal"}),(0,u.jsx)(Re.Y,{value:"Palmate",label:"Palmate"})]}),(0,u.jsxs)(Re.Y.Group,{style:{marginTop:"5%"},label:"What type of image is this?",onChange:c,value:a.imageType||"",children:[(0,u.jsx)(Re.Y,{value:"Light Microscope",label:"Light Microscope"}),(0,u.jsx)(Re.Y,{value:"SEM",label:"SEM"})]})]})},Xe=["Please use .tif and .jpg format for images and limit the size to at max 10 MB. [We recommend keeping some blank space around the image; ","","To edit an existing fossil, choose the fossil type from the top left corner and select the specific fossil from the dropdown menu to make changes. Regular instructors can only edit fossils they uploaded; the main FossilSketch catalog is editable only by super-instructors.","","After uploading a fossil, make sure to enable it for the database page b
1y activating it from the 'Select Content' page.","You can upload multiple specimens of the same fossil type under the same name, but only one will be displayed on the database page."],De=[{name:"Max Length",value:"max_length"},{name:"Max Height",value:"max_height"},{name:"Outline",value:"outline"}],Le=[{name:"Outline",value:"outline"},{name:"Last Chamber",value:"last_chamber"},{name:"Center Outline",value:"center_outline"},{name:"Aperture Area",value:"aperture_area"}];var Be=function(e){var a=e.handleLogout,l=function(e,a){ge((0,Pe.Kk)(e,a))},m=function(){if(ue&&ve){var e=ve.split("/");(0,Pe.ao)(e[e.length-1],T.fossilType).catch((function(e){return console.warn(e)})),de(null)}else(0,Pe.ao)(T.imagePath,T.fossilType).catch((function(e){return console.warn(e)}));"Foraminifera"===T.fossilType?Da({fossilID:xe+1,fossilType:T.fossilType}):Da({fossilID:Oe+1,fossilType:T.fossilType})},_=function(e){return e.map((function(e,a){return(0,u.jsx)(v.m.Tab,{style:{fontSize:"18px"},value:e.value,children:e.name.toUpperCase()},a)}))},C=function(e){V(!1),me(null),M&&!e||(1==ne&&m(),O({type:"clear"}),de(null),X(!1),H(null),ie(null),Be(""),ge(null),re(0),ua(!1),La())},w=function(e,a,l,t){var n=(0,Pe.Ix)(e,t).then((function(e){if(e){var n,r=function(e){try{var a,l;return null!==(l=null===(a=(e.startsWith("http")?new URL(e).pathname:e).split("/").pop())||void 0===a?void 0:a.split("?")[0])&&void 0!==l?l:""}catch(r){var t,n;return null!==(n=null===(t=e.split("/").pop())||void 0===t?void 0:t.split("?")[0])&&void 0!==n?n:""}}(e);ge(null!==(n=(0,Pe.Kk)(e,t))&&void 0!==n?n:e),r&&(a?R(W.user):de(null),O({type:"saveFossil",payload:{imagePath:r,id:l}}))}})).catch((function(e){throw console.warn(e),(0,Se.c0)({id:"fossilImageUploadFailed",title:"Image upload failed",message:(0,r.Z)(e,Error)?e.message:String(e),color:"red",autoClose:8e3}),a&&X(!1),e})).finally((function(){Aa.current===n&&(Aa.current=null)}));return Aa.current=n,n},S=function(){he&&(O({type:"load",payload:{genus:he.genus,species:he.species}}),le(he.notes.map((function(e){return(0,o.Z)({},e)}))),me(null))},k=(0,Ye.EA)(),T=k.fossilState,O=k.fossilDispatch,A=k.ostracodaRadio,N=k.ostracodaCheckbox,F=k.ostracodaInput,z=k.validateFossilFields,P=k.foraminiferaRadio,E=k.foraminiferaCheckbox,Y=k.setFossilType,R=(k.setSpecies,k.setCreatedBy),W=(0,d.useContext)(ke.Z),I=(0,d.useState)(!1),M=I[0],X=I[1],D=(0,d.useState)("foraminifera"),L=D[0],B=D[1],U=(0,d.useState)(null),Z=U[0],H=U[1],G=(0,d.useState)(!1),$=G[0],V=G[1],ee=(0,d.useState)([{key:"location",value:""},{key:"age",value:""},{key:"ecology",value:""},{key:"",value:""}]),ae=ee[0],le=ee[1],te=(0,d.useState)(0),ne=te[0],re=te[1],oe=(0,d.useState)(null),se=oe[0],ie=oe[1],ce=(0,d.useState)(null),ue=ce[0],de=ce[1],pe=(0,d.useState)(null),he=pe[0],me=pe[1],fe=(0,d.useState)(null),ve=fe[0],ge=fe[1],be=(0,d.useState)(0),xe=be[0],ye=be[1],je=(0,d.useState)(0),Oe=je[0],Ae=je[1],Re=(0,d.useState)("outline"),We=Re[0],Be=Re[1],Ue=(0,d.useState)(!1),Ze=Ue[0],He=Ue[1],Ge=(0,d.useState)(!1),$e=Ge[0],Ve=Ge[1],Ke=(0,d.useState)(!1),Qe=Ke[0],Je=Ke[1],qe=(0,d.useState)(!1),ea=qe[0],aa=qe[1],la=(0,d.useState)(!1),ta=la[0],na=la[1],ra=(0,d.useState)(!1),oa=ra[0],sa=ra[1],ia=(0,d.useState)(!1),ca=ia[0],ua=ia[1],da=(0,d.useState)(!1),pa=da[0],ha=da[1],ma=(0,d.useState)(!1),fa=ma[0],va=ma[1],ga=(0,d.useState)(T.outline),ba=ga[0],xa=ga[1],ya=(0,d.useState)(0),ja=ya[0],_a=ya[1],Ca=(0,d.useState)(0),wa=Ca[0],Sa=Ca[1],ka=(0,d.useState)(!1),Ta=ka[0],Oa=ka[1],Aa=(0,d.useRef)(null),Na=ze.S.useQuery(["classroom.getFossilList"]),Fa=Na.data,za=Na.refetch,Pa=Na.isError,Ea=Na.error,Ya=(0,d.useMemo)((function(){if(!(null===Fa||void 0===Fa?void 0:Fa.forams))return[];var e=Fa.forams.map((function(e){return{id:e.id,value:"".concat(e.id,"#").concat(e.genus,"#").concat(e.species),label:"".concat(e.genus," ").concat(e.species),group:"foraminifera"}}));return e.sort((function(e,a){return e.label.toUpperCase()<a.label.toUpperCase()?-1:e.label.toUpperCase()>a.label.toUpperCase()?1:0})),e}),[Fa]),Ra=(0,d.useMemo)((function(){if(!(null===Fa||void 0===Fa?void 0:Fa.ostracods))return[];var e=Fa.ostracods.map((function(e){return{id:e.id,value:"".concat(e.id,"#").concat(e.genus,"#").concat(e.species),label:"".concat(e.genus," ").concat(e.species),group:"ostracoda"}}));return e.sort((function(e,a){return e.label.toUpperCase()<a.label.toUpperCase()?-1:e.label.toUpperCase()>a.label.toUpperCase()?1:0})),e}),[Fa]),Wa=(0,d.useMemo)((function(){return"foraminifera"===L?Ya:Ra}),[L,Ya,Ra]);(0,d.useEffect)((function(){null!=Fa&&(ye(Fa.lastForamId),Ae(Fa.lastOstracodId))}),[Fa]);var Ia=ze.S.useMutation(["classroom.getFossil"],{onSuccess:function(e){void 0!=e.fossilData&&("morphotype"in e.fossilData?(l(e.fossilData.imagePath,"Foraminifera"),O({type:"initialLoadForam",payload:(0,o.Z)({},e.fossilData)}
1)):(l(e.fossilData.imagePath,"Ostracoda"),O({type:"initialLoadOstracod",payload:(0,o.Z)({},e.fossilData)})),Oa(!0)),e.notesData&&le(e.notesData)},onError:function(e){Oa(!1),(0,Se.c0)({id:"getFossilFailed",title:"Failed to load fossil",message:e.message||"Could not load fossil details",color:"red",autoClose:8e3})}}),Ma=Ia.mutate,Xa=ze.S.useMutation("classroom.saveFossilNotes").mutate,Da=ze.S.useMutation("classroom.deleteFossil").mutate,La=function(){le([{key:"location",value:""},{key:"age",value:""},{key:"ecology",value:""},{key:"",value:""}])};function Ba(){return(Ba=(0,t.Z)((function(){var e,a,l,t,n,r,o,s,i,u,d;return(0,c.__generator)(this,(function(c){switch(c.label){case 0:if(!Aa.current)return[3,4];c.label=1;case 1:return c.trys.push([1,3,,4]),[4,Aa.current];case 2:return c.sent(),[3,4];case 3:return c.sent(),e={},(0,Se.c0)((e.id="imageUploadPendingFailed",e.title="Image upload failed",e.message="Fix the image upload error before saving.",e.color="red",e.autoClose=8e3,e)),[2];case 4:return O(((a={}).type="saveFossil",a)),l={},Ze&&O((l.type="saveSketch",l.payload={sketchType:"outline"},l)),t={},$e&&O((t.type="saveSketch",t.payload={sketchType:"majorAxis"},t)),n={},Qe&&O((n.type="saveSketch",n.payload={sketchType:"minorAxis"},n)),r={},ea&&O((r.type="saveSketch",r.payload={sketchType:"largestChamber"},r)),o={},ta&&O((o.type="saveSketch",o.payload={sketchType:"centerOutline"},o)),s={},oa&&O((s.type="saveSketch",s.payload={sketchType:"apertureArea"},s)),u={},Xa(((i={}).fossilId=T.id,i.data=ae,i.fossilType=T.fossilType,i),(u.onSuccess=function(){(0,Se.c0)({id:"saveFossilNotesData",title:"Notes saved",message:"Notes data saved for fossil",color:"green",autoClose:5e3})},u.onError=function(e){var a=e.message||"Error adding notes for the fossil";(0,Se.c0)({id:"emptyOrDuplicateNotes",title:"Error adding notes",message:a,color:"red",autoClose:5e3})},u)),He(!1),Ve(!1),Je(!1),aa(!1),na(!1),sa(!1),1==ne&&re(3),O(((d={}).type="clear",d)),de(null),X(!1),H(null),ie(null),Be(""),ge(null),re(0),ua(!1),La(),za(),[2]}}))}))).apply(this,arguments)}var Ua="Foraminifera"===T.fossilType&&!(!T.modelPath||!T.modelPath.trim());function Za(){return(Za=(0,t.Z)((function(){var e,a,l;return(0,c.__generator)(this,(function(t){switch(t.label){case 0:S(),e=T.id,a={},0===ne&&(re(1),e="Foraminifera"===T.fossilType?xe+1:Oe+1,O((a.type="load",a.payload={id:e},a))),t.label=1;case 1:return t.trys.push([1,6,,7]),se?[4,w(se,!0,e,T.fossilType)]:[3,3];case 2:t.sent(),t.label=3;case 3:return ue?(l={},!Ta||e<=0?((0,Se.c0)((l.id="fossilNotReadyForImageReplace",l.title="Fossil still loading",l.message="Wait for the fossil to finish loading, then try again.",l.color="red",l.autoClose=8e3,l)),[2]):[4,w(ue,!1,e,T.fossilType)]):[3,5];case 4:t.sent(),t.label=5;case 5:return[3,7];case 6:return t.sent(),[2];case 7:return Be("outline"),V(!1),X(!0),ua(!0),[2]}}))}))).apply(this,arguments)}var Ha=M&&""!==T.imagePath,Ga=Ha&&he?he.notes:ae,$a=function(e){Ha&&he?me((0,s.Z)((0,o.Z)({},he),{notes:e})):le(e)},Va=function(e,a){var l=a.target.name;if("key"!=l||0!=e&&1!=e&&2!=e){var t=(0,i.Z)(Ga);t[e]=(0,s.Z)((0,o.Z)({},t[e]),(0,n.Z)({},l,a.target.value)),$a(t)}},Ka=function(e){return 0===e||1===e||2===e?(0,u.jsx)(u.Fragment,{}):e===Ga.length-1?(0,u.jsx)(g.z,{color:"green",classNames:{root:f().notes_button},onClick:function(){$a((0,i.Z)(Ga).concat([{key:"",value:""}]))},children:(0,u.jsx)(Te.Z,{})}):(0,u.jsx)(g.z,{color:"red",classNames:{root:f().notes_button},onClick:function(){return function(e){var a=(0,i.Z)(Ga);a.splice(e,1),$a(a)}(e)},children:(0,u.jsx)(Ne,{})})},Qa=function(){return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(b.x,{style:{textTransform:"uppercase",textAlign:"center"},children:"Ostracod"}),[{label:"Right/Left Valve",prop:"variation",type:"value"},{label:"Valve Shape",prop:"shape",type:"value"},{label:"Size",prop:"size",type:"array"},{label:"Smooth/Ornamented?",prop:"smoothOrnamented",type:"value"},{label:"Ornamentation",prop:"ornamentation",type:"array"},{label:"Other Carapace Features",prop:"otherFeatures",type:"array"}].map((function(e,a){var l;return(0,u.jsxs)(b.x,{children:[(0,u.jsxs)("span",{className:f().fossil_value,children:[e.label,": "]}),"value"===e.type?T[e.prop]:null===(l=T[e.prop])||void 0===l?void 0:l.map((function(a,l){return(0,u.jsxs)(b.x,{style:{display:"inline"},children:[a,l<T[e.prop].length-2?",":""," "]},l)}))]},a+e.label)}))]})},Ja=function(){return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(b.x,{style:{textTransform:"uppercase",textAlign:"center"},children:"Foraminifera"}),[{label:"Shell Type",prop:"shellType",type:"value"},{label:"Overall Shape",prop:"overallShape",type:"array"},{label:"Chamber Shape",prop:"chamberShape",type:"array"},{label:"Number of Chambers",prop:"numberChambers",type:"value"},{label:"Chamber Arrangement",prop:"chamberArrangement",type:"array"},{label:"Aperture Location",prop:"apertureLocation",type:"value"},{label:"Aperture Shape",prop:"apertureShape",type:"value"},{label:"Morphotype",prop:"morphotype",type:"value"}].map((function(e,a){var l;return(0,u.jsxs)(b.x,{children:[(0,u.jsxs)("span",{className:f().fossil_value,children:[e.label,": "]}),"value"===e.type?T[e.prop]:null===(l=T[e.prop])||void 0===l?void 0:l.map((function(a,l){return(0,u.jsxs)(b.x,{style:{display:"inline"},children:[a,l<T[e.prop].length-1?",":""," "]},l)}))]},a+e.label)}))]})};(0,d.useEffect)((function(){switch(We){case"max_length":T.majorAxis!=[]&&(xa(T.majorAxis),_a(T.majorAxisCanvasHeight),Sa(T.majorAxisCanvasWidth));break;case"max_height":T.minorAxis!=[]&&(xa(T.minorAxis),_a(T.minorAxisCanvasHeight),Sa(T.minorAxisCanvasWidth));break;case"outline":T.outline!=[]&&(xa(T.outline),_a(T.outlineCanvasHeight),Sa(T.outlineCanvasWidth));break;case"last_chamber":T.largestChamber!=[]&&(xa(T.largestChamber),_a(T.largestChamberCanvasHeight),Sa(T.largestChamberCanvasWidth));break;case"center_outline":T.centerOutline!=[]&&(xa(T.centerOutline),_a(T.centerOutlineCanvasHeight),Sa(T.centerOutlineCanvasWidth));break;case"aperture_area":T.apertureArea!=[]&&(xa(T.apertureArea),_a(T.apertureAreaCanvasHeight),Sa(T.apertureAreaCanvasWidth));break;default:xa([])}}),[We,T.id,T.fossilType,T.imagePath,T.outline,T.majorAxis,T.minorAxis,T.largestChamber,T.centerOutline,T.apertureArea,T.outlineCanvasHeight,T.outlineCanvasWidth,T.majorAxisCanvasHeight,T.majorAxisCanvasWidth,T.minorAxisCanvasHeight,T.minorAxisCanvasWidth,T.largestChamberCanvasHeight,T.largestChamberCanvasWidth,T.centerOutlineCanvasHeight,T.centerOutlineCanvasWidth,T.apertureAreaCanvasHeight,T.apertureAreaCanvasWidth]),(0,d.useEffect)((function(){return 1==ne||ue?(window.addEventListener("beforeunload",m),Ee.Router.events.on("routeChangeStart",m)):(window.removeEventListener("beforeunload",m),Ee.Router.events.off("routeChangeStart",m)),function(){window.removeEventListener("beforeunload",m),Ee.Router.events.off("routeChangeStart",m)}}),[ne,T.imagePath,ve]);var qa,el=function(e,a){switch(a){case 0:return(0,u.jsxs)(u.Fragment,{children:[e," see"," ",(0,u.jsx)("a",{href:"https://storage.googleapis.com/fossil
1sketch/ostracoda/ostracod%20demo%20image.jpg",target:"_blank",className:f().link,children:"this"})," ","for reference]"]});case 1:return(0,u.jsxs)(u.Fragment,{children:["To upload a new fossil, click the ",(0,u.jsx)("button",{children:"New Microfossil"})," ","button and enter the required details."]});case 3:return(0,u.jsxs)(u.Fragment,{children:["To switch between fossils during editing, close the current fossil by clicking the ",(0,u.jsx)("button",{children:"X"})," button and then open the one you want to work on next."]});default:return e}};return(0,u.jsxs)("div",{className:f().background,children:[(0,u.jsx)(p.Z,{handleLogout:a}),!M&&!$&&(0,u.jsxs)(x.X,{className:f().instruction_modal,children:[(0,u.jsx)(y.D,{className:f().instruction_modal_title,children:"Instructions to upload a new fossil"}),(0,u.jsx)("a",{href:"https://youtu.be/98_yIATyzeg?si=puNaakrNjfj-O3-c",target:"_blank",className:f().video_guide,children:(0,u.jsx)(b.x,{color:"yellow",children:"Watch Video guide"})}),(0,u.jsx)("ol",{children:Xe.map((function(e,a){return(0,u.jsx)("li",{children:(0,u.jsx)(b.x,{children:el(e,a)})},a)}))}),(0,u.jsxs)(b.x,{children:[(0,u.jsx)("span",{style:{color:"red"},children:"Note:"})," Dropdown menu is searchable. You can directly search the fossil name you wish to edit."]})]}),(0,u.jsx)(j.u,{opened:$,onClose:function(){C(!1)},title:M?"Edit Microfossil":"New Microfossil",closeOnClickOutside:!1,children:(0,u.jsxs)("div",{className:f().modal_container,children:[(0,u.jsx)(K,{label:Ha?(0,u.jsxs)("span",{children:["Upload Fossil Image"," ",(0,u.jsx)("span",{style:{color:"gray"},children:"(optional \u2014 to replace)"})]}):"Upload Fossil Image",description:Ha?"Current image: ".concat(T.imagePath):void 0,placeholder:Ha?"Choose replacement image":"Fossil Image",value:Ha?ue:se,onChange:function(e){Ha?e&&de(e):ie(e)},style:{marginBottom:"10px"},clearable:!Ha,withAsterisk:!Ha}),(0,u.jsx)(Q.o,{placeholder:"Genus Name",label:"Genus Name",withAsterisk:!0,value:Ha&&he?he.genus:T.genus,onChange:function(e){var a=e.currentTarget.value;Ha&&he?me((0,s.Z)((0,o.Z)({},he),{genus:a})):O({type:"load",payload:{genus:a}})},style:{marginBottom:"10px"}}),(0,u.jsx)(Q.o,{placeholder:"Species Name",label:(0,u.jsxs)("span",{children:["Species Name ",(0,u.jsx)("span",{style:{color:"gray"},children:"(optional)"})]}),value:Ha&&he?he.species:T.species,onChange:function(e){var a=e.currentTarget.value;Ha&&he?me((0,s.Z)((0,o.Z)({},he),{species:a})):O({type:"load",payload:{species:a}})},style:{marginBottom:"10px"}}),(0,u.jsxs)(u.Fragment,{children:[(0,u.jsxs)(b.x,{style:{fontSize:"14px",fontWeight:500},children:["Notes ",(0,u.jsx)("span",{style:{color:"grey"},children:"(optional)"})," -"," ",(0,u.jsx)(J.u,{position:"top",arrowSize:8,withArrow:!0,label:"Use this fields to add extra information about fossils which can be used for filtering",children:(0,u.jsx)("span",{style:{color:"red"},children:"info"})})]}),Ga.map((function(e,a){return(0,u.jsx)("div",{style:{paddingBottom:"10px"},children:(0,u.jsxs)(q.r,{children:[(0,u.jsx)(q.r.Col,{span:5,children:(0,u.jsx)(Q.o,{name:"key",placeholder:"key",value:e.key,onChange:function(e){return Va(a,e)}})}),(0,u.jsx)(q.r.Col,{span:5,children:(0,u.jsx)(Q.o,{name:"value",placeholder:"value",value:e.value,onChange:function(e){return Va(a,e)}})}),(0,u.jsx)(q.r.Col,{span:2,children:Ka(a)})]})},a)}))]}),(0,u.jsx)(_e,{style:{width:"80%",marginTop:"5%"},value:T.fossilType,onChange:Y,disabled:ca,data:[{label:"Ostracoda",value:"Ostracoda"},{label:"Foraminifera",value:"Foraminifera"}]}),"Foraminifera"==T.fossilType&&(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(K,{label:(0,u.jsxs)("span",{children:["Upload CT / 3-D Model"," ",(0,u.jsx)("span",{style:{color:"gray"},children:"(.glb, .gltf, or .stl \u2014 max 200 MB, optional)"})]}),placeholder:"Select .glb / .gltf / .stl file",accept:".glb,.gltf,.stl,model/gltf-binary,model/gltf+json,model/stl",onChange:function(){var e=(0,t.Z)((function(e){var a,l,t,n,o,s,i,u;return(0,c.__generator)(this,(function(c){switch(c.label){case 0:if(!e)return[2];a=(e.size/1048576).toFixed(1),c.label=1;case 1:return c.trys.push([1,3,,4]),l={},(0,Se.c0)((l.id="modelUploading",l.title="Uploading 3D model\u2026 0%",l.message="".concat(e.name," (").concat(a," MB)"),l.color="blue",l.loading=!0,l.autoClose=!1,l.disallowClose=!0,l)),[4,(0,Pe.NO)(e,(function(l){(0,Se.wD)({id:"modelUploading",title:"Uploading 3D model\u2026 ".concat(l.percentage,"%"),message:"".concat(e.name," (").concat(a," MB)"),color:"blue",loading:!0,autoClose:!1,disallowClose:!0})}))];case 2:return t=c.sent(),O(((n={}).type="load",n.payload={modelPath:t},n)),o={},T.id>0&&O((o.type="saveFossil",o.payload={modelPath:t},o)),s={},(0,Se.wD)((s.id="modelUploading",s.title="3D model uploaded",s.message=e.name,s.color="green",s.loading=!1,s.autoClose=4e3,s.disallowClose=!1,s)),[3,4];case 3:return i=c.sent(),u={},(0,Se.wD)((u.id="modelUploading",u.title="Upload failed",u.message=(0,r.Z)(i,Error)?i.message:String(i),u.color="red",u.loading=!1,u.autoClose=8e3,u.disallowClose=!1,u)),[3,4];case 4:return[2]}}
1))}));return function(a){return e.apply(this,arguments)}}(),style:{marginTop:"10px",marginBottom:"10px"}}),(0,u.jsx)(Q.o,{placeholder:"https://sketchfab.com/... or GCS URL",label:(0,u.jsxs)("span",{children:["CT / 3-D Model URL"," ",(0,u.jsx)("span",{style:{color:"gray"},children:"(optional)"})]}),value:null!==(qa=T.modelPath)&&void 0!==qa?qa:"",onChange:function(e){return O({type:"load",payload:{modelPath:e.currentTarget.value}})},style:{marginTop:"10px",marginBottom:"10px"}})]}),"Ostracoda"==T.fossilType&&(0,u.jsx)(Ie,{fossilState:T,radioControl:A,checkboxControl:N,inputControl:F}),"Foraminifera"==T.fossilType&&(0,u.jsx)(Me,{fossilState:T,radioControl:P,checkboxControl:E}),(0,u.jsx)(g.z,{className:f().upload_ok,onClick:function(){return Za.apply(this,arguments)},disabled:!(Ha&&he?he.genus:T.genus).trim()||!(!Ha||!ue||Ta&&!(T.id<=0))||""==T.fossilType||!z(T),children:M?"Save":"Ok"})]})}),(0,u.jsxs)("div",{className:f().page_editor_layout,children:[(0,u.jsxs)("div",{className:"".concat(f().container," ").concat(f().main_column),children:[(0,u.jsxs)("div",{className:f().topbar,children:[(0,u.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:14,flexWrap:"wrap"},children:[(0,u.jsx)(y.D,{order:4,className:f().fossil_name,style:{margin:0},children:"New Microfossil"}),(0,u.jsx)(_e,{value:L,onChange:B,size:"md",data:[{label:"Foraminifera",value:"foraminifera"},{label:"Ostracoda",value:"ostracoda"}]}),(0,u.jsx)(Ce.Ph,{placeholder:"Edit Existing Fossil",value:Z,onChange:function(e){H(e),X(!0),re(2),ge(null),Oa(!1);var a=Ya,l=(a=a.concat(Ra)).find((function(a){return a.value===e}));l&&(Ma({fossilId:l.id,fossilType:l.group}),Be("outline"),ua(!0))},data:Wa,searchable:!0,nothingFound:"No fossils",withinPortal:!0,zIndex:200,style:{minWidth:240,flex:"1 1 200px",maxWidth:420},styles:{dropdown:{background:"#173f3f",border:"1px solid rgba(255,255,255,0.15)",boxShadow:"0 12px 24px rgba(0,0,0,0.35)"}}}),(0,u.jsx)(g.z,{radius:"xl",onClick:function(){M?(ie(null),me({genus:T.genus,species:T.species,notes:ae.map((function(e){return(0,o.Z)({},e)}))})):me(null),V(!0)},children:M?"Edit Microfossil":"New Microfossil"})]}),(0,u.jsx)("div",{style:{marginLeft:"auto",display:"flex",gap:10},children:M&&(0,u.jsx)(g.z,{radius:"xl",color:"red",variant:"filled",size:"md",onClick:function(){Da({fossilID:T.id,fossilType:T.fossilType},{onSuccess:function(){O({type:"clear"}),de(null),X(!1),H(null),ie(null),Be(""),ge(null),re(0),ua(!1),(0,Se.c0)({id:"deleteFossilData",title:"Fossil data deleted",message:"Fossil data successfully deleted",autoClose:5e3,color:"green"}),za()}}),La()},children:"Delete"})})]}),Pa&&(0,u.jsxs)(b.x,{color:"red",size:"sm",mt:"xs",px:"md",children:["Could not load fossils from the server. Check that the API is running and you are logged in."," ",(0,r.Z)(Ea,Error)?Ea.message:String(null!==Ea&&void 0!==Ea?Ea:"")]}),M&&(0,u.jsxs)(x.X,{shadow:"sm",p:"md",radius:"md",className:f().canvas_card,children:[(0,u.jsxs)("div",{className:f().canvas_header,children:[!$&&(""!=T.genus||""!=T.species)&&(0,u.jsxs)("div",{className:f().fossil_name_container,children:[(0,u.jsxs)(b.x,{className:f().fossil_name,children:[T.genus," ",T.species]}),(0,u.jsx)(we.A,{variant:"filled",onClick:function(){return C(!0)},children:(0,u.jsx)(Fe.Z,{size:32})})]}),(0,u.jsx)(v.m,{defaultValue:We,value:We,onTabChange:Be,children:(0,u.jsxs)(v.m.List,{children:["Foraminifera"==T.fossilType&&_(Le),"Ostracoda"==T.fossilType&&_(De)]})})]}),(0,u.jsx)(h.Z,{fossilFilePath:ve,points:ba,originalCanvasHeight:ja,originalCanvasWidth:wa,sketchHandler:function(e){switch(We){case"outline":O({type:"load",payload:{outline:e}}),He(!0);break;case"max_length":O({type:"load",payload:{majorAxis:e}}),Ve(!0);break;case"max_height":O({type:"load",payload:{minorAxis:e}}),Je(!0);break;case"last_chamber":O({type:"load",payload:{largestChamber:e}}),aa(!0);break;case"center_outline":O({type:"load",payload:{centerOutline:e}}),na(!0);break;case"aperture_area":O({type:"load",payload:{apertureArea:e}}),sa(!0)}},canvasSizeHandler:function(e,a,l){""!=l&&O({type:"updateCanvasSize",payload:{canvasHeight:e,canvasWidth:a,sketchTab:l}})},sketchTab:We,editMode:!0})]}),M&&(0,u.jsx)("div",{className:f().edit_buttons,children:(0,u.jsx)(u.Fragment,{children:(0,u.jsx)(g.z,{color:"green",radius:"xl",size:"lg",disabled:!Ua&&("Foraminifera"!==T.fossilType||0==T.outline.length||0==T.largestChamber.length||0==T.centerOutline.length||0==T.apertureArea.length)&&("Ostracod
1a"!==T.fossilType||0==T.majorAxis.length||0==T.minorAxis.length||0==T.outline.length),onClick:function(){return Ba.apply(this,arguments)},children:"Save Fossil"})})})]}),M&&(0,u.jsxs)("div",{className:f().editor_rail,children:[(0,u.jsxs)("div",{className:f().sidebar_container,children:[(0,u.jsxs)("div",{className:f().minimize_sidebar,children:[(0,u.jsxs)(we.A,{variant:"transparent",onClick:function(){ha(!pa)},children:[pa&&(0,u.jsx)(Te.Z,{size:32}),!pa&&(0,u.jsx)(Ne,{size:32})]}),(0,u.jsx)(b.x,{style:{fontSize:"20px"},children:"Microfossil Properties"})]}),(0,u.jsx)("div",{style:{display:pa?"none":"flex"},className:f().sidebar,children:(0,u.jsx)("div",{className:f().fossil_properties,children:"Ostracoda"===T.fossilType?(0,u.jsx)(Qa,{}):(0,u.jsx)(Ja,{})})})]}),(0,u.jsx)("div",{className:f().sidebar_container,children:(0,u.jsxs)("div",{children:[(0,u.jsxs)("div",{className:f().minimize_sidebar,children:[(0,u.jsxs)(we.A,{variant:"transparent",onClick:function(){va(!fa)},children:[fa&&(0,u.jsx)(Te.Z,{size:32}),!fa&&(0,u.jsx)(Ne,{size:32})]}),(0,u.jsx)(b.x,{style:{fontSize:"20px"},children:"Microfossil Notes"})]}),(0,u.jsx)("div",{style:{display:fa?"none":"flex"},className:f().sidebar,children:(0,u.jsx)("div",{className:f().fossil_properties,children:null===ae||void 0===ae?void 0:ae.map((function(e,a){return(0,u.jsxs)(b.x,{children:[(0,u.jsxs)("span",{className:f().fossil_value,children:[e.key,":"," "]}),e.value]},"".concat(e.key,"-").concat(a))})).slice(0,ae.length-1)})})]})})]})]})]})}},8327:function(e){e.exports={background:"new_fossil_background____QOE",instruction_modal:"new_fossil_instruction_modal__MjfUm",instruction_modal_title:"new_fossil_instruction_modal_title__rIz8t",video_guide:"new_fossil_video_guide__sZMSB",link:"new_fossil_link__E10nl",page_editor_layout:"new_fossil_page_editor_layout__FBfc3",editor_rail:"new_fossil_editor_rail__eLwGa",main_column:"new_fossil_main_column__h6KmC",container:"new_fossil_container__No3_8",step_select:"new_fossil_step_select__dSLOi",step:"new_fossil_step__9hsY4",topbar:"new_fossil_topbar__KE4iL",select:"new_fossil_select__rg7RR",sidebar_container:"new_fossil_sidebar_container__Pe6Wv",minimize_sidebar:"new_fossil_minimize_sidebar__JK28H",sidebar:"new_fossil_sidebar__mW48M",fossil_properties:"new_fossil_fossil_properties__wNGl5",fossil_value:"new_fossil_fossil_value__t5rXG",modal_container:"new_fossil_modal_container__UQY3N",upload_image:"new_fossil_upload_image__b0_QA",upload_ok:"new_fossil_upload_ok__ncC5e",fossil_name:"new_fossil_fossil_name__YDost",fossil_name_container:"new_fossil_fossil_name_container__MKA0R",canvas_card:"new_fossil_canvas_card__haaUt",canvas_header:"new_fossil_canvas_header__OxAC7",canvas_title:"new_fossil_canvas_title__N1Sw_",edit_buttons:"new_fossil_edit_buttons__m2bVo",notes_button:"new_fossil_notes_button__g8vJ_"}},9236:function(e,a,l){"use strict";l.d(a,{D:function(){return w}});var t=l(2784),n=l(4761),r=l(6817),o=Object.defineProperty,s=Object.defineProperties,i=Object.getOwnPropertyDescriptors,c=Object.getOwnPropertySymbols,u=Object.prototype.hasOwnProperty,d=Object.prototype.propertyIsEnumerable,p=(e,a,l)=>a in e?o(e,a,{enumerable:!0,configurable:!0,writable:!0,value:l}):e[a]=l,h=(e,a)=>{for(var l in a||(a={}))u.call(a,l)&&p(e,l,a[l]);if(c)for(var l of c(a))d.call(a,l)&&p(e,l,a[l]);return e};function m(e,a,l){return"undefined"!==typeof e?e in l.headings.sizes?l.headings.sizes[e].fontSize:e:l.headings.sizes[a].fontSize}function f(e,a,l){return"undefined"!==typeof e&&e in l.headings.sizes?l.headings.sizes[e].lineHeight:l.headings.sizes[a].lineHeight}var v=(0,r.k)(((e,{element:a,weight:l,size:t,inline:n})=>{return{root:(r=h({},e.fn.fontStyles()),o={fontFamily:e.headings.fontFamily,fontWeight:l||e.headings.sizes[a].fontWeight||e.headings.fontWeight,fontSize:m(t,a,e),lineHeight:n?1:f(t,a,e),margin:0},s(r,i(o)))};var r,o})),g=l(5117),b=Object.defineProperty,x=Object.getOwnPropertySymbols,y=Object.prototype.hasOwnProperty,j=Object.prototype.propertyIsEnumerable,_=(e,a,l)=>a in e?b(e,a,{enumerable:!0,configurable:!0,writable:!0,value:l}):e[a]=l;const C={order:1},w=(0,t.forwardRef)(((e,a)=>{const l=(0,n.N4)("Title",C,e),{className:r,order:o,children:s,unstyled:i,size:c,weight:u,inline:d}=l,p=((e,a)=>{var l={};for(var t in e)y.call(e,t)&&a.indexOf(t)<0&&(l[t]=e[t]);if(null!=e&&x)for(var t of x(e))a.indexOf(t)<0&&j.call(e,t)&&(l[t]=e[t]);return l})(l,["className","order","children","unstyled","size","weight","inline"]),{classes:h,cx:m}=v({element:`h${o}`,weight:u,size:c,inline:d},{name:"Title",unstyled:i});return[1,2,3,4,5,6].includes(o)?t.createElement(g.x,((e,a)=>{for(var l in a||(a={}))y.call(a,l)&&_(e,l,a[l]);if(x)for(var l of x(a))j.call(a,l)&&_(e,l,a[l]);return e})({component:`h${o}`,ref:a,className:m(h.root,r)},p),s):null}));w.displayName="@mantine/core/Title"}},function(e){e.O(0,[786,7311,6577,443,7301,5944,8855,7530,8238,9472,7464,9774,2888,179],(function(){return a=3451,e(e.s=a);var a}));var a=e.O();_N_E=a}]);

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.