docs/cjs/ion-button_14.cjs.entry.js
// Called by push, pull, and offset since they use the same calculations
Called by push, pull, and offset since they use the same calculations
Called by push pull and offset since they use the same calculations
calculatePosition(property, modifier) {
    const columns = this.getColumns(property);
    if (!columns) {
      return;
    }
    const amount = SUPPORTS_VARS
      // If CSS supports variables we should use the grid columns var
      ? `calc(calc(${columns} / var(--ion-grid-columns, 12)) * 100%)`
      : (columns > 0 && columns < 12) ? (columns / 12 * 100) + '%' : 'auto';
    return {
      [modifier]: amount
    };
  }
calculatePosition ( property , modifier ) { const columns = this . getColumns ( property ) ; if ( ! columns ) { return ; } const amount = SUPPORTS_VARS ? ` ${ columns } ` : ( columns > 0 && columns < 12 ) ? ( columns / 12 * 100 ) + '%' : 'auto' ; return { [ modifier ] : amount } ; }
Called by push, pull, and offset since they use the same calculations
Called by push pull and offset since they use the same calculations
// If the number of columns passed are greater than 0 and less than // 12 we can position the column, else default to auto // Convert the columns to a percentage by dividing by the total number // of columns (12) and then multiplying by 100