|
- function makeFurniture() {
- results = [];
-
- const dataSofas = [
- {
- name: "Two Seat",
- sides: {
- "Front": { height: math.unit(30, "inches") },
- "Side": { height: math.unit(30, "inches") },
- "Top": { height: math.unit(30.5, "inches") },
- }
- },
- ]
-
- results.push({
- name: "Sofas",
- constructor: () => makeAutoVehicleGroup(dataSofas,
- "Sofas",
- "furniture")
- });
-
- results.push(
- makeHeight(
- [
- ["twin", 75, "inches"],
- ["twin-xl", 80, "inches"],
- ["twin-xl", 80, "inches"],
- ["full", 75, "inches"],
- ["queen", 80, "inches"],
- ["king", 80, "inches"],
- ["california-king", 84, "inches"],
- ],
- "Mattresses",
- "",
- "furniture"
- )
- )
-
- results.sort((b1, b2) => {
- e1 = b1.constructor();
- e2 = b2.constructor();
- return -math.subtract(e1.views[e1.defaultView].height, e2.views[e2.defaultView].height).value;
- });
-
- return results;
- }
|