How to navigate to a specific element in another page?

Suppose I have my “/” page and another page “/Blog”. I want to go from /Blog to /#Blogs, which is a route containing the specific element ID. I am trying to do this using the Link component. ChatGPT tells me that I have to use onCLick in my Link to manually scroll to #Blogs. Is there a better way? As someone new to Next JS I want to know what you guys would do in this situation.

here is the code snippet for my Link component:

      <Link
    href={displayAll ? "/#Blogs" : "/Blog"}
    scroll={false}
    className="block w-fit m-auto text-[1.4rem] mb-[25rem]"
  >
    {displayAll ? "Back Home" : "Read more"}
  </Link>

P.s, I successfully navigate to localhost:3000/#Blogs, but I am redirected to the top of the page, rather than the element with id=”Blogs”

Render BotFramework webchat in shadow dom

I have a requirement to render the webchat from BotFramework-Webchat in a shadowDom to prevent css leakage to an embedding site.
According to this GitHub Issue: BotFramework-Webchat issue 5194 and according to this PR: BotFramework-Webchat PR 5196 I should be able to render a webchat in a shadow dom. Unfortunately there is no “How to” to do so, I’ve tried to infer the usage from the unit tests in the PR but have not gotten it to render correctly.

Here is the short section of TS where I’m trying to render the webchat in a shadow dom.

export const startChat = async (serviceName: string, clientId?: string): Promise<void> => {
  const user = await requestToken(serviceName);
  if (user === null) return;

  webchatState.user = user;
  initializeDirectLine();

  const shadowRoot = document.body.attachShadow({ mode: "open" });
  const container = document.createElement("div");
  container.id = "webchat";
  shadowRoot.appendChild(container);

  const styleOptions: WebChat.IStyleOptions = {
    avatarBorderRadius: "50%",
    avatarSize: 40,
    botAvatarBackground: getCssVariableValue("--secondary"),
    botAvatarBackgroundColor: getCssVariableValue("--secondary"),
    botAvatarImage: chatbotAvatarImg,
    botAvatarInitials: "",
    bubbleBackground: getCssVariableValue("--primary"),
    bubbleBorderRadius: "15px",
    bubbleBorderStyle: "solid",
    bubbleBorderWidth: 1,
    bubbleFromUserBackground: getCssVariableValue("--secondary"),
    bubbleFromUserBorderColor: getCssVariableValue("--primary"),
    bubbleFromUserBorderRadius: "15px",
    bubbleFromUserBorderStyle: "solid",
    bubbleFromUserBorderWidth: 1,
    bubbleFromUserTextColor: getCssVariableValue("--text-secondary"),
    bubbleTextColor: getCssVariableValue("--secondary"),
    hideUploadButton: true,
    sendBoxBackground: "White",
    sendBoxBorderBottom: "",
    sendBoxBorderLeft: "",
    sendBoxBorderRight: "",
    sendBoxBorderTop: `solid 1px ${getCssVariableValue("--primary")}`,
    sendBoxButtonColor: getCssVariableValue("--primary"),
    sendBoxHeight: 40,
    sendBoxTextColor: "Black",
    stylesRoot: shadowRoot,
    userAvatarBackgroundColor: getCssVariableValue("--secondary"),
    userAvatarImage: userAvatarImg,
    userAvatarInitials: "",
  };

  if (container !== null) {
    window.WebChat.renderWebChat(
      {
        directLine: webchatState.directLine,
        userID: webchatState.user.id,
        styleOptions,
      },
      container
    );
  }
  await sendClientIdActivity(clientId);
  await sendRequestWelcomeMessage();
  await sendStartBot();
};

Here is the current result which is equal to the issue in the GitHub issue which I assume is the standard UI just without the styles that have not been applied because of the shadow dom.
enter image description here

Things I’ve checked:

  • The functions before the render complete successfully establishing a connection to the directline and the user information.
  • The botframework cdn is collecting from the latest version
  • The types being used are correct for the style root which needs to be recieved by the bot framework styleOptions

As reference here is the type definition for IStyleOptions which was created based on the type in the botframework repository:

interface IStyleOptions {
    [index: string]: number | string | boolean | Node;
    avatarBorderRadius: string;
    avatarSize: number;
    botAvatarBackground: string;
    botAvatarBackgroundColor: string;
    botAvatarImage: string;
    botAvatarInitials: string;
    bubbleBackground: string;
    bubbleBorderRadius: string;
    bubbleBorderStyle: string;
    bubbleBorderWidth: number;
    bubbleFromUserBackground: string;
    bubbleFromUserBorderColor: string;
    bubbleFromUserBorderRadius: string;
    bubbleFromUserBorderStyle: string;
    bubbleFromUserBorderWidth: number;
    bubbleFromUserTextColor: string;
    bubbleTextColor: string;
    hideUploadButton: boolean;
    sendBoxBackground: string;
    sendBoxBorderBottom: string;
    sendBoxBorderLeft: string;
    sendBoxBorderRight: string;
    sendBoxBorderTop: string;
    sendBoxButtonColor: string;
    sendBoxHeight: number;
    sendBoxTextColor: string;
    stylesRoot: Node;
    userAvatarBackgroundColor: string;
    userAvatarImage: string;
    userAvatarInitials: string;
  }

hi i am a commerce student and I wanna build a website for my school which is a interactive website and also have a application, how do I start [closed]

I want a roadmap to learn

I am confused that how this works

I mean a website which has a seperate login page for users also which can generate I’d cards by profiles.

what database does excel will be use or SQL or oracle

how to launch

I came to know that a web hosting platform and domain I need but apart from that what kind of database I should use I have no idea

FilePond not showing previews of loaded local existing pdf on laravel

I use FilePond to show displays existing data like image and pdf. When displaying images it works but when displaying pdf: Invalid PDF structure.
I saved the file in storage and run artisan storage command

this my code on controller

    $proposal = Proposal::find($id);
    if (!$proposal) {
        return redirect()->back()->with('error', 'Proposal not found.');
    }
    $files = $proposal->files();
    $filePondFiles = Files::whereIn('id', json_decode($proposal->proposal_file_id))->get()->map(function ($file) {
        return [
            'source' => asset($file->file_path),
            'options' => [
                'type' => 'local',
                'metadata' => [
                    'poster' => asset($file->file_path)
                ], 
                'file' => [
                    'name' => $file->file_name,
                    'size' => $file->file_size,
                    'type' => $file->file_type,
                ],
            ],
        ];
    }); 

and this my script :

    // Register the plugins
FilePond.registerPlugin(
    FilePondPluginFileValidateType,
    FilePondPluginFileEncode,
    FilePondPluginFileValidateSize,
    FilePondPluginImageExifOrientation,
    FilePondPluginImagePreview,
    FilePondPluginPdfPreview,
    FilePondPluginFilePoster,
);

// Inisialisasi FilePond
const filePondElement = document.querySelector('input.filepond');
const initialFiles = @json($filePondFiles);
const pond = FilePond.create(filePondElement, {
    files: initialFiles,
    allowReorder: true,
    allowMultiple: true,
    acceptedFileTypes: [
        'application/msword',
        'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
        'application/vnd.ms-excel',
        'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
        'application/vnd.ms-powerpoint',
        'application/vnd.openxmlformats-officedocument.presentationml.presentation',
        'application/pdf',
        'image/*',
        'video/*',
        'audio/*',
    ],
    pdfPreviewHeight: 200,
    pdfComponentExtraParams: 'toolbar=0&navpanes=0&scrollbar=0',
    filePosterHeight: 150,
    labelFileTypeNotAllowed: 'File type not allowed',
    fileValidateTypeLabelExpectedTypes: 'Expects {allButLastType} or {lastType}',
});

Filter a object based on another Array

I am trying to filter a object based on an another array.

data = {
  'TypeA': ['A1', 'A2', 'A3', 'A4'],
  'TypeB': ['B1', 'B2', 'B3', 'B4'],
  'TypeC': ['C1', 'C2', 'C3', 'C4'],
}

array = ['TypeA', 'TypeB']

I want to get a new array with the values of both ‘TypeA’ and ‘TypeB’ like [‘A1’, ‘A2’, ‘A3’, ‘A4’, ‘B1’, ‘B2’, ‘B3’, ‘B4’] and remove duplicates if any also.

so far i have tried,

tTmp_Arr = data.filter(tObj => array.includes(tObj))

Any help is much appreciated.

Thanks in advance.

Thanks,

JavaScript is not working as per our expectation in transforming the card from its original position

I have multiple card in the card_section, and in card there is also a div named card_img. I was writing a query for each card that when we click on any card the card_img changes its position to the left of card_section through the transform property, but its parent means card doesn’t change its position. But in this, we don’t know how many card are there in a single row so we make a function getCardsPerRow to calculate how many cards are there in a row then finally if the width of card_section changes, the function of getCardsPerRow also changes.

My submission is that my queries are working fine for fir row whether it has 2 card, 3 card, or 5 card, but in the second row, it is not working as expected.

Please help me to solve this query.

Following are the HTML-

<div class="team_main_container">
    <div class="team_cards_container">
        <div class="card_section">
            <div class="card">
                <div class="card_img">Card 1 </div>
            </div>
            <div class="card">
                <div class="card_img">Card 2 </div>
            </div>
            <div class="card">
                <div class="card_img">Card 3 </div>
            </div>
            <div class="card">
                <div class="card_img">Card 4 </div>
            </div>
            <div class="card">
                <div class="card_img">Card 5 </div>
            </div>
            <div class="card">
                <div class="card_img">Card 6 </div>
            </div>
            <div class="card">
                <div class="card_img">Card 7 </div>
            </div>
            <div class="card">
                <div class="card_img">Card 8 </div>
            </div>
            <div class="card">
                <div class="card_img">Card 9 </div>
            </div>
            <div class="card">
                <div class="card_img">Card 10 </div>
            </div>
        </div>
    </div>
</div>

Following are the CSS-

.team_main_container {
border: 2px solid red;
width: 100%;
height: 100%;
display: flex;
align-items: flex-start;
justify-content: center;
}

.team_main_container .team_cards_container {
border: 2px solid green;
width: 90%;
height: 100%;
display: flex;
flex-direction: column;
align-items: flex-start;
justify-content: center;
}

.team_main_container .team_cards_container .card_section {
border: 2px solid red;
width: 100%;
display: flex;
flex-wrap: wrap;
gap: 20px;
}

.team_main_container .team_cards_container .card_section .card {
width: calc((100% / 6) - 16px);
height: 30rem;
cursor: pointer;
border: 2px solid red;
position: relative;
}

.team_main_container .team_cards_container .card_section .card .card_img {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
object-fit: cover;
transition: transform 0.3s ease-in-out;
background-color: #2b2525;
color: #fff;
border: 2px solid #45ba00;
}

:root {
--offset-percent: 0%; /* Default percentage offset */
--offset-pixel: 0px; /* Default pixel offset */
}

.team_main_container .team_cards_container .card_section .card .card_img.transform_to_left {
transform: translateX(calc(var(--offset-percent) + var(--offset-pixel)));
transition: transform 0.3s ease; /* Add a smooth transition */
}

Following are the JavaScript-

// Function to calculate the number of cards per row dynamically
function getCardsPerRow() {
const cardSection = document.querySelector(".card_section");
const card = document.querySelector(".card");

if (!card || !cardSection) return 1; // Default to 1 if elements are not found

const containerWidth = cardSection.offsetWidth;

const cardStyle = getComputedStyle(card);
const cardWidth = card.offsetWidth;
const cardMarginLeft = parseFloat(cardStyle.marginLeft);
const cardMarginRight = parseFloat(cardStyle.marginRight);
const totalCardWidth = cardWidth + cardMarginLeft + cardMarginRight;

return Math.floor(containerWidth / totalCardWidth);
}

// Main script
const cards = document.querySelectorAll(".card");
const root = document.documentElement; // Refers to :root in CSS

// Function to update the card behaviors dynamically
function setupCardTransformations() {
const cardsPerRow = getCardsPerRow(); // Calculate cards per row dynamically

cards.forEach((card, index) => {
card.addEventListener("click", () => {
const columnIndex = index % cardsPerRow; // Column index (0, 1, 2, etc.)
const rowIndex = Math.floor(index / cardsPerRow); // Row index (0, 1, 2, etc.)

// Calculate offsets based on column position
const offsetPercent = -100 * columnIndex; // Percentage offset for column
const offsetPixel = -20 * columnIndex; // Pixel offset for column

// Update CSS variables dynamically
root.style.setProperty("--offset-percent", `${offsetPercent}%`);
root.style.setProperty("--offset-pixel", `${offsetPixel}px`);

// Add transform class to clicked card
const img = card.querySelector(".card_img");
img.classList.toggle("transform_to_left");

// Optionally remove the class from other cards
cards.forEach((otherCard) => {
if (otherCard !== card) {
otherCard.querySelector(".card_img").classList.remove(
"transform_to_left");
}
});
});
});
}

// Initialize card transformations and update on resize
setupCardTransformations();
window.addEventListener("resize", () => {
setupCardTransformations(); // Recalculate and rebind the logic on resize
});

Why is my mouse hovering offset from actual element selected?

Purple dot is element being hovered on, red dot is where the mouse is.

Full repo here

Site hosted here

For whatever reason, my mouse is offset down and to the right of what it is supposedly hovering over inside of a mapbox map. It doesn’t line up. The red dot in the image is where my mouse is and the purple dot with the popup is where it is ‘hovering’ over to be selected. It persists to all elements on the map, including the other point layer and the polygon layer.
It is also not dependent on zoom level. It is offset by a fixed amount no matter what the zoom is.

    mapboxgl.accessToken = 'pk.eyJ1IjoibWFwdXNlcjAzIiwiYSI6ImNtMHpzYTFiZzAyd2cyanBrYWhpYXZsZ3gifQ.paRv0YlSRjmXUZKSMTjGEA';
        const mymap = new mapboxgl.Map({
            container: 'map',
            style: 'mapbox://styles/mapbox/dark-v11',
            projection: 'mercator',
            center: [-122.32070, 47.61360],
            zoom:10.79
        });

        mymap.on('load', () => {
            mymap.addSource('income', {
                    type: 'geojson',
                    data: 'census_tracts_income_schools.geojson'

                    });  

            mymap.addSource('publicschools', {
                type: 'geojson',
                data: 'Public_Schools_Seattle.geojson'
            });


            mymap.addSource('privateschools', {
                type: 'geojson',
                data: 'Private_Schools_Seattle.geojson'
            });


            mymap.addLayer( {
                    id: 'income-layer',
                    type: 'fill',
                    source: 'income',
                    layout: {
                        'visibility': 'visible'
                    },
                    paint: {
                    'fill-color':['interpolate',['linear'],['get', 'B19301_per_capita_income_5YALL_B19301_001'],
                                    24000, '#ffffcc',
                                    50000, '#a1dab4',
                                    75000, '#41b6c4',
                                    100000, '#2c7fb8',
                                    150000, '#253494'],
                    'fill-outline-color':'lightgrey'    
                        }
                    }); 

            mymap.addLayer( {
                id: 'public-schools-layer',
                type: 'circle',
                source: 'publicschools',
                layout: {
                        'visibility': 'visible'
                    },
                paint: {
                        'circle-radius': 6,
                        'circle-color': "#ffaf0f",
                        'circle-stroke-width': 1,
                        'circle-stroke-color': 'white',
                        'circle-stroke-opacity': 0.6,
                        'circle-opacity': 0.9
                    }
            });

            mymap.addLayer( {
                id: 'private-schools-layer',
                type: 'circle',
                source: 'privateschools',
                layout: {
                        'visibility': 'visible'
                    },
                paint: {
                        'circle-radius': 6,
                        'circle-color': "#cf10e0",
                        'circle-stroke-width': 1,
                        'circle-stroke-color': 'white',
                        'circle-stroke-opacity': 0.6,
                        'circle-opacity': 0.9
                    }
            });  
        });  

    // Add click event for public schools
    mymap.on('click', 'public-schools-layer', (event) => {
        const features = event.features;
        if (!features || !features.length) return;

        const properties = features[0].properties;

        // Create a popup and set its content
        new mapboxgl.Popup()
            .setLngLat(event.lngLat)
            .setHTML(`
                <h3 class="popup">Public School</h3>
                <p class="popup"><strong>Name:</strong> ${properties.school_name || 'N/A'}</p>
                <p class="popup"><strong>Address:</strong> ${properties.address || 'N/A'}</p>
                <p class="popup"><strong>Grades:</strong> ${properties.grades || 'N/A'}</p>
            `)
            .addTo(mymap);
    });   
    
    mymap.on('click', 'private-schools-layer', (event) => {
    const features = event.features;
    if (!features || !features.length) return;

    const properties = features[0].properties;

    // Create a popup and set its content
    new mapboxgl.Popup()
        .setLngLat(event.lngLat)
        .setHTML(`
            <h3 class="popup">Private School</h3>
            <p class="popup"><strong>Name:</strong> ${properties.NAME || 'N/A'}</p>
            <p class="popup"><strong>Address:</strong> ${properties.SCHOOL_STREET_ADDRESS || 'N/A'}</p>
            <p class="popup"><strong>Profit/Nonprofit:</strong> ${properties.FOR_PROFIT_OR_NON_PROFIT || 'N/A'}</p>
        `)
        .addTo(mymap);
    });

I made sure that my data was in the right projection for a mapbox mercator (EPSG:3857) in QGIS. Didn’t seem to change anything. Not sure what else it could be.

How to remove the horizontal scrollbar everytime v-select dropdown area is clicked

How to remove this horinzontal scrollbar that is appearing everytime i click the v-select data items.It will only popup 1sec then it will be gone Ive already tried using overflow-x ,y ,and others methods but all didnt work.

I already tried adding height in the v-card and width but still it didnt fix the issue.

Output of horizontal scrollbar only appear 1 sec and will be gone

This is my vuejs

    <template>
    <div class="vue-container" v-if="state.isCreated">
        <div class="vue-content">
            <v-layout d-flex align-center justify-center style='height: 80vh'>
                <v-row justify="center">
                    <v-col col="3" xs="3" sm="3" md="3" lg="3">
                        <v-card tile class="transaction-card">
                            <v-simple-table dense>
                                <div class="table-header">
                                    <div class="title">
                                        <span>PAYMENT PRIORITY MANAGEMENT</span>
                                    </div>
                                </div>
                            </v-simple-table>
                            <v-form class="form-section">
                                <v-simple-table
                                    dense
                                    class="grouped-rows striped bordered highlight"
                                >
                                    <template>
                                        <thead>
                                            <tr>
                                                <th align="center" width="70">
                                                    Priority #
                                                </th>
                                                <th align="center" width="200">
                                                    Amortization
                                                </th>
                                            </tr>
                                        </thead>
                                    </template>
                                    <template>
                                        <tbody
                                            v-for="(item, index) in bracketBalance"
                                            :key="index"
                                        >
                                            <tr class="ba-1">
                                                <td align="center">
                                                    {{ index + 1 }}.
                                                </td>
                                                <td
                                                    v-if="showupdate"
                                                    class="text-center"
                                                >
                                                    <v-select
                                                        :error="
                                                            item.error
                                                        "
                                                        :items="priority.data"
                                                        :boundInput="item.tempid"
                                                        
                                                        solo
                                                        dense
                                                        height="5px"
                                                        hide-details
                                                        @change="
                                                            changeItems(
                                                                $event,
                                                                index,
                                                                item.tempid
                                                            )
                                                        "
                                                    ></v-select>
                                                </td>
                                                <td v-else-if="initialView">
                                                    {{ item.priority }}
                                                </td>
                                            </tr>
                                        </tbody>
                                        <tbody>
                                            <tr class="ba-1">
                                                <td align="center">8.</td>
                                                <td>Principal</td>
                                            </tr>
                                        </tbody>
                                    </template>
                                </v-simple-table>
                            </v-form>
                            <v-layout
                                align-center
                                justify-center
                                style="padding-top: 10px"
                            >
                                <v-flex>
                                    <div class="text-center">
                                        <v-btn
                                            small
                                            v-if="showedit"
                                            tile
                                            v-on:click="editBracketBalance"
                                            >Edit</v-btn
                                        >
                                        <v-btn
                                            small
                                            v-if="showupdate"
                                            tile
                                            v-on:click="checkError"
                                            class="mr-10"
                                            >Save</v-btn
                                        >
                                        <v-btn
                                            v-if="showupdate"
                                            tile
                                            small
                                            v-on:click="initialView"
                                            >Back</v-btn
                                        >
                                    </div>
                                </v-flex>
                            </v-layout>
                        </v-card>
                    </v-col>
                </v-row>
            </v-layout>
        </div>
    </div>
</template>

<style lang="scss" scoped>
.shortcutkey {
    width: 100%;
    height: 40px;
    text-indent: 8px;
}

/* ::v-deep .v-select-list > .v-list-item.v-list-item--disabled {
    color: black !important;
} */
::v-deep .v-select .v-select__selection--disabled{
  color: black !important;
}
</style>

Zoom Video stream on Mobile Browser While using getUserMedia

I am using getUserMedia in my web page to open user’s camera and then capture image from the video stream. On Desktop it works fine, but on mobile devices, the pinch zoom zooms in the entire web page, I want only the video element to be zoomed in and when I capture the image, the zoomed image should be captured on canvas. Below is my code:

const startCamera = (facingMode?: string | { exact: string }) => {
    if (navigator.mediaDevices && navigator.mediaDevices.getUserMedia) {
      let facingModeSupported = true;
      if (
        navigator.mediaDevices &&
        navigator.mediaDevices.getSupportedConstraints &&
        facingMode
      ) {
        const supports = navigator.mediaDevices.getSupportedConstraints();
        if (!supports['facingMode']) {
          facingModeSupported = false;
        }
      }
      navigator.mediaDevices
        .getUserMedia({
          audio: false,
          video: facingModeSupported && facingMode
            ? {
                facingMode: facingMode ? facingMode : 'user',
              }
            : true,
        })
        .then((stream) => {
          streamTracks.current = stream;
          if (cameraVideoStream.current) {
            cameraVideoStream.current.srcObject = stream;
            cameraVideoStream.current.addEventListener('loadedmetadata', () => {
              if (cameraVideoStream.current) {
                cameraVideoStream.current.play();
              }
            });
          }
        })
        .catch((e) => {
        });
    }
  };

Below is the Code to Capture the Image:

if (canvasRef.current) {
      const canvasContext = canvasRef.current.getContext('2d');
      if (canvasContext && cameraVideoStream.current) {
        canvasRef.current.width = window.innerWidth;
        canvasRef.current.height = window.innerHeight;
        const videoAspect =
          cameraVideoStream.current.videoWidth /
          cameraVideoStream.current.videoHeight;
        const canvasAspect = canvasRef.current.width / canvasRef.current.height;
        let renderWidth,
          renderHeight,
          offsetX = 0,
          offsetY = 0;
        if (videoAspect > canvasAspect) {
          renderHeight = canvasRef.current.height;
          renderWidth = renderHeight * videoAspect;
          offsetX = -(renderWidth - canvasRef.current.width) / 2;
        } else {
          renderWidth = canvasRef.current.width;
          renderHeight = renderWidth / videoAspect;
          offsetY = -(renderHeight - canvasRef.current.height) / 2;
        }
        if (cameraMode === 'front') {
          canvasContext.translate(window.innerWidth, 0);
          canvasContext.scale(-1, 1);
        }
        canvasContext?.drawImage(
          cameraVideoStream.current,
          0,
          0,
          cameraVideoStream.current.videoWidth,
          cameraVideoStream.current.videoHeight,
          offsetX,
          offsetY,
          renderWidth,
          renderHeight
        );
        const data = canvasRef.current.toDataURL('image/png');
        stopCamera();
      }
    }

How do I use Bootstrap 5.3.3 css and have the buttons back to their original colours with glyphicons?

I have been using Dropzone.js for a few years and have an app that has been working well. There are three buttons that are used.

<span class="btn btn-success fileinput-button">
    <i class="glyphicon glyphicon-plus"></i>
    <span>Browse files...</span>
</span>
<button class="btn btn-primary start">
    <i class="glyphicon glyphicon-upload"></i>
    <span>Start</span>
</button>
<button data-dz-remove class="btn btn-danger delete">
   <i class="glyphicon glyphicon-trash"></i>
   <span>Remove</span>
</button>

I have been using [email protected]/dist/css/bootstrap.min.css from cdn.jsdelivr.net and as I said it works well. The buttons look like this:

enter image description here

I would now like to add a modal but it doesn’t work with Bootstrap 3.1.1

If I use [email protected]/dist/css/bootstrap.min.css from cdn.jsdelivr.net the buttons look like this:

enter image description here

The modal works but the button colour is slightly different and I have lost the glyphicons.

I would like to use the latest version possible of the Bootstrap css.
If I use [email protected]/dist/css/bootstrap.min.css from cdn.jsdelivr.net the buttons look like this:

enter image description here

The modal works but again the button colours are slightly different and the glyphicons have disappeared. Also the Remove button only has an outline and no fill.

How do I use Bootstrap 5.3.3 css and have the buttons back to their original colours with glyphicons?

Ultimately I would like to use my own custom coloured buttons with either glyphicons or font-awesome icons. Is this possible?

How to View Windchill .pvz Files Directly in Mendix Using REST APIs?

I’m working on a Mendix application where my customer needs to view Windchill .pvz files (3D CAD files) directly within the application before downloading them. The files are being fetched from a REST API with basic authentication.

If anyone has experience with a similar use case, I’d appreciate insights or references to suitable solutions.

What I’ve Tried

  • Fetching .pvz Files: Successfully retrieved the .pvz files using REST APIs in Mendix.
  • Viewing .pvz Files: Tried rendering the files in a viewer within Mendix, but no success so far.
  • External Tools: Explored using CreoView and other CAD viewers, but they often require launching a separate application.

Expecting:

  1. The solution should allow users to view .pvz files directly within Mendix without needing to download or open them in external applications.
  2. The viewer must support 3D CAD formats like .pvz.

Thank you in advance for your help!

How can I programmatically change the color of the hamburger menu icon?

I’m trying to change the color of the hamburger menu icon in a mobile view using Velo in Wix. However, when I attempt to set the color using the following code:

$w.onReady(function () {
    $w("#menuToggle1").style.color = "red";
});

I receive the error: Property ‘style’ does not exist on type ‘HiddenCollapsedElement’.

I understand that the style property is not applicable here. What is the correct way to change the icon color of the menuToggle component programmatically? Any guidance or examples would be greatly appreciated!